diff --git a/kubernetes/.openapi-generator/COMMIT b/kubernetes/.openapi-generator/COMMIT
index 9bb39c57de..e55d78f521 100644
--- a/kubernetes/.openapi-generator/COMMIT
+++ b/kubernetes/.openapi-generator/COMMIT
@@ -1,2 +1,2 @@
-Requested Commit/Tag : v4.3.0
-Actual Commit : c224cf484b020a7f5997d883cf331715df3fb52a
+Requested Commit/Tag : v6.6.0
+Actual Commit : 7f8b853f502d9039c9a0aac2614ce92871e895ed
diff --git a/kubernetes/.openapi-generator/FILES b/kubernetes/.openapi-generator/FILES
new file mode 100644
index 0000000000..2abf9f2f58
--- /dev/null
+++ b/kubernetes/.openapi-generator/FILES
@@ -0,0 +1,2399 @@
+.gitlab-ci.yml
+README.md
+client/__init__.py
+client/api/__init__.py
+client/api/admissionregistration_api.py
+client/api/admissionregistration_v1_api.py
+client/api/admissionregistration_v1alpha1_api.py
+client/api/admissionregistration_v1beta1_api.py
+client/api/apiextensions_api.py
+client/api/apiextensions_v1_api.py
+client/api/apiregistration_api.py
+client/api/apiregistration_v1_api.py
+client/api/apis_api.py
+client/api/apps_api.py
+client/api/apps_v1_api.py
+client/api/authentication_api.py
+client/api/authentication_v1_api.py
+client/api/authorization_api.py
+client/api/authorization_v1_api.py
+client/api/autoscaling_api.py
+client/api/autoscaling_v1_api.py
+client/api/autoscaling_v2_api.py
+client/api/batch_api.py
+client/api/batch_v1_api.py
+client/api/certificates_api.py
+client/api/certificates_v1_api.py
+client/api/certificates_v1alpha1_api.py
+client/api/certificates_v1beta1_api.py
+client/api/coordination_api.py
+client/api/coordination_v1_api.py
+client/api/coordination_v1alpha2_api.py
+client/api/coordination_v1beta1_api.py
+client/api/core_api.py
+client/api/core_v1_api.py
+client/api/custom_objects_api.py
+client/api/discovery_api.py
+client/api/discovery_v1_api.py
+client/api/events_api.py
+client/api/events_v1_api.py
+client/api/flowcontrol_apiserver_api.py
+client/api/flowcontrol_apiserver_v1_api.py
+client/api/internal_apiserver_api.py
+client/api/internal_apiserver_v1alpha1_api.py
+client/api/logs_api.py
+client/api/networking_api.py
+client/api/networking_v1_api.py
+client/api/networking_v1beta1_api.py
+client/api/node_api.py
+client/api/node_v1_api.py
+client/api/openid_api.py
+client/api/policy_api.py
+client/api/policy_v1_api.py
+client/api/rbac_authorization_api.py
+client/api/rbac_authorization_v1_api.py
+client/api/resource_api.py
+client/api/resource_v1_api.py
+client/api/resource_v1alpha3_api.py
+client/api/resource_v1beta1_api.py
+client/api/resource_v1beta2_api.py
+client/api/scheduling_api.py
+client/api/scheduling_v1_api.py
+client/api/scheduling_v1alpha1_api.py
+client/api/storage_api.py
+client/api/storage_v1_api.py
+client/api/storage_v1beta1_api.py
+client/api/storagemigration_api.py
+client/api/storagemigration_v1beta1_api.py
+client/api/version_api.py
+client/api/well_known_api.py
+client/api_client.py
+client/configuration.py
+client/exceptions.py
+client/models/__init__.py
+client/models/admissionregistration_v1_service_reference.py
+client/models/admissionregistration_v1_webhook_client_config.py
+client/models/apiextensions_v1_service_reference.py
+client/models/apiextensions_v1_webhook_client_config.py
+client/models/apiregistration_v1_service_reference.py
+client/models/authentication_v1_token_request.py
+client/models/core_v1_endpoint_port.py
+client/models/core_v1_event.py
+client/models/core_v1_event_list.py
+client/models/core_v1_event_series.py
+client/models/core_v1_resource_claim.py
+client/models/discovery_v1_endpoint_port.py
+client/models/events_v1_event.py
+client/models/events_v1_event_list.py
+client/models/events_v1_event_series.py
+client/models/flowcontrol_v1_subject.py
+client/models/rbac_v1_subject.py
+client/models/resource_v1_resource_claim.py
+client/models/storage_v1_token_request.py
+client/models/v1_affinity.py
+client/models/v1_aggregation_rule.py
+client/models/v1_allocated_device_status.py
+client/models/v1_allocation_result.py
+client/models/v1_api_group.py
+client/models/v1_api_group_list.py
+client/models/v1_api_resource.py
+client/models/v1_api_resource_list.py
+client/models/v1_api_service.py
+client/models/v1_api_service_condition.py
+client/models/v1_api_service_list.py
+client/models/v1_api_service_spec.py
+client/models/v1_api_service_status.py
+client/models/v1_api_versions.py
+client/models/v1_app_armor_profile.py
+client/models/v1_attached_volume.py
+client/models/v1_audit_annotation.py
+client/models/v1_aws_elastic_block_store_volume_source.py
+client/models/v1_azure_disk_volume_source.py
+client/models/v1_azure_file_persistent_volume_source.py
+client/models/v1_azure_file_volume_source.py
+client/models/v1_binding.py
+client/models/v1_bound_object_reference.py
+client/models/v1_capabilities.py
+client/models/v1_capacity_request_policy.py
+client/models/v1_capacity_request_policy_range.py
+client/models/v1_capacity_requirements.py
+client/models/v1_cel_device_selector.py
+client/models/v1_ceph_fs_persistent_volume_source.py
+client/models/v1_ceph_fs_volume_source.py
+client/models/v1_certificate_signing_request.py
+client/models/v1_certificate_signing_request_condition.py
+client/models/v1_certificate_signing_request_list.py
+client/models/v1_certificate_signing_request_spec.py
+client/models/v1_certificate_signing_request_status.py
+client/models/v1_cinder_persistent_volume_source.py
+client/models/v1_cinder_volume_source.py
+client/models/v1_client_ip_config.py
+client/models/v1_cluster_role.py
+client/models/v1_cluster_role_binding.py
+client/models/v1_cluster_role_binding_list.py
+client/models/v1_cluster_role_list.py
+client/models/v1_cluster_trust_bundle_projection.py
+client/models/v1_component_condition.py
+client/models/v1_component_status.py
+client/models/v1_component_status_list.py
+client/models/v1_condition.py
+client/models/v1_config_map.py
+client/models/v1_config_map_env_source.py
+client/models/v1_config_map_key_selector.py
+client/models/v1_config_map_list.py
+client/models/v1_config_map_node_config_source.py
+client/models/v1_config_map_projection.py
+client/models/v1_config_map_volume_source.py
+client/models/v1_container.py
+client/models/v1_container_extended_resource_request.py
+client/models/v1_container_image.py
+client/models/v1_container_port.py
+client/models/v1_container_resize_policy.py
+client/models/v1_container_restart_rule.py
+client/models/v1_container_restart_rule_on_exit_codes.py
+client/models/v1_container_state.py
+client/models/v1_container_state_running.py
+client/models/v1_container_state_terminated.py
+client/models/v1_container_state_waiting.py
+client/models/v1_container_status.py
+client/models/v1_container_user.py
+client/models/v1_controller_revision.py
+client/models/v1_controller_revision_list.py
+client/models/v1_counter.py
+client/models/v1_counter_set.py
+client/models/v1_cron_job.py
+client/models/v1_cron_job_list.py
+client/models/v1_cron_job_spec.py
+client/models/v1_cron_job_status.py
+client/models/v1_cross_version_object_reference.py
+client/models/v1_csi_driver.py
+client/models/v1_csi_driver_list.py
+client/models/v1_csi_driver_spec.py
+client/models/v1_csi_node.py
+client/models/v1_csi_node_driver.py
+client/models/v1_csi_node_list.py
+client/models/v1_csi_node_spec.py
+client/models/v1_csi_persistent_volume_source.py
+client/models/v1_csi_storage_capacity.py
+client/models/v1_csi_storage_capacity_list.py
+client/models/v1_csi_volume_source.py
+client/models/v1_custom_resource_column_definition.py
+client/models/v1_custom_resource_conversion.py
+client/models/v1_custom_resource_definition.py
+client/models/v1_custom_resource_definition_condition.py
+client/models/v1_custom_resource_definition_list.py
+client/models/v1_custom_resource_definition_names.py
+client/models/v1_custom_resource_definition_spec.py
+client/models/v1_custom_resource_definition_status.py
+client/models/v1_custom_resource_definition_version.py
+client/models/v1_custom_resource_subresource_scale.py
+client/models/v1_custom_resource_subresources.py
+client/models/v1_custom_resource_validation.py
+client/models/v1_daemon_endpoint.py
+client/models/v1_daemon_set.py
+client/models/v1_daemon_set_condition.py
+client/models/v1_daemon_set_list.py
+client/models/v1_daemon_set_spec.py
+client/models/v1_daemon_set_status.py
+client/models/v1_daemon_set_update_strategy.py
+client/models/v1_delete_options.py
+client/models/v1_deployment.py
+client/models/v1_deployment_condition.py
+client/models/v1_deployment_list.py
+client/models/v1_deployment_spec.py
+client/models/v1_deployment_status.py
+client/models/v1_deployment_strategy.py
+client/models/v1_device.py
+client/models/v1_device_allocation_configuration.py
+client/models/v1_device_allocation_result.py
+client/models/v1_device_attribute.py
+client/models/v1_device_capacity.py
+client/models/v1_device_claim.py
+client/models/v1_device_claim_configuration.py
+client/models/v1_device_class.py
+client/models/v1_device_class_configuration.py
+client/models/v1_device_class_list.py
+client/models/v1_device_class_spec.py
+client/models/v1_device_constraint.py
+client/models/v1_device_counter_consumption.py
+client/models/v1_device_request.py
+client/models/v1_device_request_allocation_result.py
+client/models/v1_device_selector.py
+client/models/v1_device_sub_request.py
+client/models/v1_device_taint.py
+client/models/v1_device_toleration.py
+client/models/v1_downward_api_projection.py
+client/models/v1_downward_api_volume_file.py
+client/models/v1_downward_api_volume_source.py
+client/models/v1_empty_dir_volume_source.py
+client/models/v1_endpoint.py
+client/models/v1_endpoint_address.py
+client/models/v1_endpoint_conditions.py
+client/models/v1_endpoint_hints.py
+client/models/v1_endpoint_slice.py
+client/models/v1_endpoint_slice_list.py
+client/models/v1_endpoint_subset.py
+client/models/v1_endpoints.py
+client/models/v1_endpoints_list.py
+client/models/v1_env_from_source.py
+client/models/v1_env_var.py
+client/models/v1_env_var_source.py
+client/models/v1_ephemeral_container.py
+client/models/v1_ephemeral_volume_source.py
+client/models/v1_event_source.py
+client/models/v1_eviction.py
+client/models/v1_exact_device_request.py
+client/models/v1_exec_action.py
+client/models/v1_exempt_priority_level_configuration.py
+client/models/v1_expression_warning.py
+client/models/v1_external_documentation.py
+client/models/v1_fc_volume_source.py
+client/models/v1_field_selector_attributes.py
+client/models/v1_field_selector_requirement.py
+client/models/v1_file_key_selector.py
+client/models/v1_flex_persistent_volume_source.py
+client/models/v1_flex_volume_source.py
+client/models/v1_flocker_volume_source.py
+client/models/v1_flow_distinguisher_method.py
+client/models/v1_flow_schema.py
+client/models/v1_flow_schema_condition.py
+client/models/v1_flow_schema_list.py
+client/models/v1_flow_schema_spec.py
+client/models/v1_flow_schema_status.py
+client/models/v1_for_node.py
+client/models/v1_for_zone.py
+client/models/v1_gce_persistent_disk_volume_source.py
+client/models/v1_git_repo_volume_source.py
+client/models/v1_glusterfs_persistent_volume_source.py
+client/models/v1_glusterfs_volume_source.py
+client/models/v1_group_resource.py
+client/models/v1_group_subject.py
+client/models/v1_group_version_for_discovery.py
+client/models/v1_grpc_action.py
+client/models/v1_horizontal_pod_autoscaler.py
+client/models/v1_horizontal_pod_autoscaler_list.py
+client/models/v1_horizontal_pod_autoscaler_spec.py
+client/models/v1_horizontal_pod_autoscaler_status.py
+client/models/v1_host_alias.py
+client/models/v1_host_ip.py
+client/models/v1_host_path_volume_source.py
+client/models/v1_http_get_action.py
+client/models/v1_http_header.py
+client/models/v1_http_ingress_path.py
+client/models/v1_http_ingress_rule_value.py
+client/models/v1_image_volume_source.py
+client/models/v1_ingress.py
+client/models/v1_ingress_backend.py
+client/models/v1_ingress_class.py
+client/models/v1_ingress_class_list.py
+client/models/v1_ingress_class_parameters_reference.py
+client/models/v1_ingress_class_spec.py
+client/models/v1_ingress_list.py
+client/models/v1_ingress_load_balancer_ingress.py
+client/models/v1_ingress_load_balancer_status.py
+client/models/v1_ingress_port_status.py
+client/models/v1_ingress_rule.py
+client/models/v1_ingress_service_backend.py
+client/models/v1_ingress_spec.py
+client/models/v1_ingress_status.py
+client/models/v1_ingress_tls.py
+client/models/v1_ip_address.py
+client/models/v1_ip_address_list.py
+client/models/v1_ip_address_spec.py
+client/models/v1_ip_block.py
+client/models/v1_iscsi_persistent_volume_source.py
+client/models/v1_iscsi_volume_source.py
+client/models/v1_job.py
+client/models/v1_job_condition.py
+client/models/v1_job_list.py
+client/models/v1_job_spec.py
+client/models/v1_job_status.py
+client/models/v1_job_template_spec.py
+client/models/v1_json_schema_props.py
+client/models/v1_key_to_path.py
+client/models/v1_label_selector.py
+client/models/v1_label_selector_attributes.py
+client/models/v1_label_selector_requirement.py
+client/models/v1_lease.py
+client/models/v1_lease_list.py
+client/models/v1_lease_spec.py
+client/models/v1_lifecycle.py
+client/models/v1_lifecycle_handler.py
+client/models/v1_limit_range.py
+client/models/v1_limit_range_item.py
+client/models/v1_limit_range_list.py
+client/models/v1_limit_range_spec.py
+client/models/v1_limit_response.py
+client/models/v1_limited_priority_level_configuration.py
+client/models/v1_linux_container_user.py
+client/models/v1_list_meta.py
+client/models/v1_load_balancer_ingress.py
+client/models/v1_load_balancer_status.py
+client/models/v1_local_object_reference.py
+client/models/v1_local_subject_access_review.py
+client/models/v1_local_volume_source.py
+client/models/v1_managed_fields_entry.py
+client/models/v1_match_condition.py
+client/models/v1_match_resources.py
+client/models/v1_modify_volume_status.py
+client/models/v1_mutating_webhook.py
+client/models/v1_mutating_webhook_configuration.py
+client/models/v1_mutating_webhook_configuration_list.py
+client/models/v1_named_rule_with_operations.py
+client/models/v1_namespace.py
+client/models/v1_namespace_condition.py
+client/models/v1_namespace_list.py
+client/models/v1_namespace_spec.py
+client/models/v1_namespace_status.py
+client/models/v1_network_device_data.py
+client/models/v1_network_policy.py
+client/models/v1_network_policy_egress_rule.py
+client/models/v1_network_policy_ingress_rule.py
+client/models/v1_network_policy_list.py
+client/models/v1_network_policy_peer.py
+client/models/v1_network_policy_port.py
+client/models/v1_network_policy_spec.py
+client/models/v1_nfs_volume_source.py
+client/models/v1_node.py
+client/models/v1_node_address.py
+client/models/v1_node_affinity.py
+client/models/v1_node_condition.py
+client/models/v1_node_config_source.py
+client/models/v1_node_config_status.py
+client/models/v1_node_daemon_endpoints.py
+client/models/v1_node_features.py
+client/models/v1_node_list.py
+client/models/v1_node_runtime_handler.py
+client/models/v1_node_runtime_handler_features.py
+client/models/v1_node_selector.py
+client/models/v1_node_selector_requirement.py
+client/models/v1_node_selector_term.py
+client/models/v1_node_spec.py
+client/models/v1_node_status.py
+client/models/v1_node_swap_status.py
+client/models/v1_node_system_info.py
+client/models/v1_non_resource_attributes.py
+client/models/v1_non_resource_policy_rule.py
+client/models/v1_non_resource_rule.py
+client/models/v1_object_field_selector.py
+client/models/v1_object_meta.py
+client/models/v1_object_reference.py
+client/models/v1_opaque_device_configuration.py
+client/models/v1_overhead.py
+client/models/v1_owner_reference.py
+client/models/v1_param_kind.py
+client/models/v1_param_ref.py
+client/models/v1_parent_reference.py
+client/models/v1_persistent_volume.py
+client/models/v1_persistent_volume_claim.py
+client/models/v1_persistent_volume_claim_condition.py
+client/models/v1_persistent_volume_claim_list.py
+client/models/v1_persistent_volume_claim_spec.py
+client/models/v1_persistent_volume_claim_status.py
+client/models/v1_persistent_volume_claim_template.py
+client/models/v1_persistent_volume_claim_volume_source.py
+client/models/v1_persistent_volume_list.py
+client/models/v1_persistent_volume_spec.py
+client/models/v1_persistent_volume_status.py
+client/models/v1_photon_persistent_disk_volume_source.py
+client/models/v1_pod.py
+client/models/v1_pod_affinity.py
+client/models/v1_pod_affinity_term.py
+client/models/v1_pod_anti_affinity.py
+client/models/v1_pod_certificate_projection.py
+client/models/v1_pod_condition.py
+client/models/v1_pod_disruption_budget.py
+client/models/v1_pod_disruption_budget_list.py
+client/models/v1_pod_disruption_budget_spec.py
+client/models/v1_pod_disruption_budget_status.py
+client/models/v1_pod_dns_config.py
+client/models/v1_pod_dns_config_option.py
+client/models/v1_pod_extended_resource_claim_status.py
+client/models/v1_pod_failure_policy.py
+client/models/v1_pod_failure_policy_on_exit_codes_requirement.py
+client/models/v1_pod_failure_policy_on_pod_conditions_pattern.py
+client/models/v1_pod_failure_policy_rule.py
+client/models/v1_pod_ip.py
+client/models/v1_pod_list.py
+client/models/v1_pod_os.py
+client/models/v1_pod_readiness_gate.py
+client/models/v1_pod_resource_claim.py
+client/models/v1_pod_resource_claim_status.py
+client/models/v1_pod_scheduling_gate.py
+client/models/v1_pod_security_context.py
+client/models/v1_pod_spec.py
+client/models/v1_pod_status.py
+client/models/v1_pod_template.py
+client/models/v1_pod_template_list.py
+client/models/v1_pod_template_spec.py
+client/models/v1_policy_rule.py
+client/models/v1_policy_rules_with_subjects.py
+client/models/v1_port_status.py
+client/models/v1_portworx_volume_source.py
+client/models/v1_preconditions.py
+client/models/v1_preferred_scheduling_term.py
+client/models/v1_priority_class.py
+client/models/v1_priority_class_list.py
+client/models/v1_priority_level_configuration.py
+client/models/v1_priority_level_configuration_condition.py
+client/models/v1_priority_level_configuration_list.py
+client/models/v1_priority_level_configuration_reference.py
+client/models/v1_priority_level_configuration_spec.py
+client/models/v1_priority_level_configuration_status.py
+client/models/v1_probe.py
+client/models/v1_projected_volume_source.py
+client/models/v1_queuing_configuration.py
+client/models/v1_quobyte_volume_source.py
+client/models/v1_rbd_persistent_volume_source.py
+client/models/v1_rbd_volume_source.py
+client/models/v1_replica_set.py
+client/models/v1_replica_set_condition.py
+client/models/v1_replica_set_list.py
+client/models/v1_replica_set_spec.py
+client/models/v1_replica_set_status.py
+client/models/v1_replication_controller.py
+client/models/v1_replication_controller_condition.py
+client/models/v1_replication_controller_list.py
+client/models/v1_replication_controller_spec.py
+client/models/v1_replication_controller_status.py
+client/models/v1_resource_attributes.py
+client/models/v1_resource_claim_consumer_reference.py
+client/models/v1_resource_claim_list.py
+client/models/v1_resource_claim_spec.py
+client/models/v1_resource_claim_status.py
+client/models/v1_resource_claim_template.py
+client/models/v1_resource_claim_template_list.py
+client/models/v1_resource_claim_template_spec.py
+client/models/v1_resource_field_selector.py
+client/models/v1_resource_health.py
+client/models/v1_resource_policy_rule.py
+client/models/v1_resource_pool.py
+client/models/v1_resource_quota.py
+client/models/v1_resource_quota_list.py
+client/models/v1_resource_quota_spec.py
+client/models/v1_resource_quota_status.py
+client/models/v1_resource_requirements.py
+client/models/v1_resource_rule.py
+client/models/v1_resource_slice.py
+client/models/v1_resource_slice_list.py
+client/models/v1_resource_slice_spec.py
+client/models/v1_resource_status.py
+client/models/v1_role.py
+client/models/v1_role_binding.py
+client/models/v1_role_binding_list.py
+client/models/v1_role_list.py
+client/models/v1_role_ref.py
+client/models/v1_rolling_update_daemon_set.py
+client/models/v1_rolling_update_deployment.py
+client/models/v1_rolling_update_stateful_set_strategy.py
+client/models/v1_rule_with_operations.py
+client/models/v1_runtime_class.py
+client/models/v1_runtime_class_list.py
+client/models/v1_scale.py
+client/models/v1_scale_io_persistent_volume_source.py
+client/models/v1_scale_io_volume_source.py
+client/models/v1_scale_spec.py
+client/models/v1_scale_status.py
+client/models/v1_scheduling.py
+client/models/v1_scope_selector.py
+client/models/v1_scoped_resource_selector_requirement.py
+client/models/v1_se_linux_options.py
+client/models/v1_seccomp_profile.py
+client/models/v1_secret.py
+client/models/v1_secret_env_source.py
+client/models/v1_secret_key_selector.py
+client/models/v1_secret_list.py
+client/models/v1_secret_projection.py
+client/models/v1_secret_reference.py
+client/models/v1_secret_volume_source.py
+client/models/v1_security_context.py
+client/models/v1_selectable_field.py
+client/models/v1_self_subject_access_review.py
+client/models/v1_self_subject_access_review_spec.py
+client/models/v1_self_subject_review.py
+client/models/v1_self_subject_review_status.py
+client/models/v1_self_subject_rules_review.py
+client/models/v1_self_subject_rules_review_spec.py
+client/models/v1_server_address_by_client_cidr.py
+client/models/v1_service.py
+client/models/v1_service_account.py
+client/models/v1_service_account_list.py
+client/models/v1_service_account_subject.py
+client/models/v1_service_account_token_projection.py
+client/models/v1_service_backend_port.py
+client/models/v1_service_cidr.py
+client/models/v1_service_cidr_list.py
+client/models/v1_service_cidr_spec.py
+client/models/v1_service_cidr_status.py
+client/models/v1_service_list.py
+client/models/v1_service_port.py
+client/models/v1_service_spec.py
+client/models/v1_service_status.py
+client/models/v1_session_affinity_config.py
+client/models/v1_sleep_action.py
+client/models/v1_stateful_set.py
+client/models/v1_stateful_set_condition.py
+client/models/v1_stateful_set_list.py
+client/models/v1_stateful_set_ordinals.py
+client/models/v1_stateful_set_persistent_volume_claim_retention_policy.py
+client/models/v1_stateful_set_spec.py
+client/models/v1_stateful_set_status.py
+client/models/v1_stateful_set_update_strategy.py
+client/models/v1_status.py
+client/models/v1_status_cause.py
+client/models/v1_status_details.py
+client/models/v1_storage_class.py
+client/models/v1_storage_class_list.py
+client/models/v1_storage_os_persistent_volume_source.py
+client/models/v1_storage_os_volume_source.py
+client/models/v1_subject_access_review.py
+client/models/v1_subject_access_review_spec.py
+client/models/v1_subject_access_review_status.py
+client/models/v1_subject_rules_review_status.py
+client/models/v1_success_policy.py
+client/models/v1_success_policy_rule.py
+client/models/v1_sysctl.py
+client/models/v1_taint.py
+client/models/v1_tcp_socket_action.py
+client/models/v1_token_request_spec.py
+client/models/v1_token_request_status.py
+client/models/v1_token_review.py
+client/models/v1_token_review_spec.py
+client/models/v1_token_review_status.py
+client/models/v1_toleration.py
+client/models/v1_topology_selector_label_requirement.py
+client/models/v1_topology_selector_term.py
+client/models/v1_topology_spread_constraint.py
+client/models/v1_type_checking.py
+client/models/v1_typed_local_object_reference.py
+client/models/v1_typed_object_reference.py
+client/models/v1_uncounted_terminated_pods.py
+client/models/v1_user_info.py
+client/models/v1_user_subject.py
+client/models/v1_validating_admission_policy.py
+client/models/v1_validating_admission_policy_binding.py
+client/models/v1_validating_admission_policy_binding_list.py
+client/models/v1_validating_admission_policy_binding_spec.py
+client/models/v1_validating_admission_policy_list.py
+client/models/v1_validating_admission_policy_spec.py
+client/models/v1_validating_admission_policy_status.py
+client/models/v1_validating_webhook.py
+client/models/v1_validating_webhook_configuration.py
+client/models/v1_validating_webhook_configuration_list.py
+client/models/v1_validation.py
+client/models/v1_validation_rule.py
+client/models/v1_variable.py
+client/models/v1_volume.py
+client/models/v1_volume_attachment.py
+client/models/v1_volume_attachment_list.py
+client/models/v1_volume_attachment_source.py
+client/models/v1_volume_attachment_spec.py
+client/models/v1_volume_attachment_status.py
+client/models/v1_volume_attributes_class.py
+client/models/v1_volume_attributes_class_list.py
+client/models/v1_volume_device.py
+client/models/v1_volume_error.py
+client/models/v1_volume_mount.py
+client/models/v1_volume_mount_status.py
+client/models/v1_volume_node_affinity.py
+client/models/v1_volume_node_resources.py
+client/models/v1_volume_projection.py
+client/models/v1_volume_resource_requirements.py
+client/models/v1_vsphere_virtual_disk_volume_source.py
+client/models/v1_watch_event.py
+client/models/v1_webhook_conversion.py
+client/models/v1_weighted_pod_affinity_term.py
+client/models/v1_windows_security_context_options.py
+client/models/v1_workload_reference.py
+client/models/v1alpha1_apply_configuration.py
+client/models/v1alpha1_cluster_trust_bundle.py
+client/models/v1alpha1_cluster_trust_bundle_list.py
+client/models/v1alpha1_cluster_trust_bundle_spec.py
+client/models/v1alpha1_gang_scheduling_policy.py
+client/models/v1alpha1_json_patch.py
+client/models/v1alpha1_match_condition.py
+client/models/v1alpha1_match_resources.py
+client/models/v1alpha1_mutating_admission_policy.py
+client/models/v1alpha1_mutating_admission_policy_binding.py
+client/models/v1alpha1_mutating_admission_policy_binding_list.py
+client/models/v1alpha1_mutating_admission_policy_binding_spec.py
+client/models/v1alpha1_mutating_admission_policy_list.py
+client/models/v1alpha1_mutating_admission_policy_spec.py
+client/models/v1alpha1_mutation.py
+client/models/v1alpha1_named_rule_with_operations.py
+client/models/v1alpha1_param_kind.py
+client/models/v1alpha1_param_ref.py
+client/models/v1alpha1_pod_group.py
+client/models/v1alpha1_pod_group_policy.py
+client/models/v1alpha1_server_storage_version.py
+client/models/v1alpha1_storage_version.py
+client/models/v1alpha1_storage_version_condition.py
+client/models/v1alpha1_storage_version_list.py
+client/models/v1alpha1_storage_version_status.py
+client/models/v1alpha1_typed_local_object_reference.py
+client/models/v1alpha1_variable.py
+client/models/v1alpha1_workload.py
+client/models/v1alpha1_workload_list.py
+client/models/v1alpha1_workload_spec.py
+client/models/v1alpha2_lease_candidate.py
+client/models/v1alpha2_lease_candidate_list.py
+client/models/v1alpha2_lease_candidate_spec.py
+client/models/v1alpha3_device_taint.py
+client/models/v1alpha3_device_taint_rule.py
+client/models/v1alpha3_device_taint_rule_list.py
+client/models/v1alpha3_device_taint_rule_spec.py
+client/models/v1alpha3_device_taint_rule_status.py
+client/models/v1alpha3_device_taint_selector.py
+client/models/v1beta1_allocated_device_status.py
+client/models/v1beta1_allocation_result.py
+client/models/v1beta1_apply_configuration.py
+client/models/v1beta1_basic_device.py
+client/models/v1beta1_capacity_request_policy.py
+client/models/v1beta1_capacity_request_policy_range.py
+client/models/v1beta1_capacity_requirements.py
+client/models/v1beta1_cel_device_selector.py
+client/models/v1beta1_cluster_trust_bundle.py
+client/models/v1beta1_cluster_trust_bundle_list.py
+client/models/v1beta1_cluster_trust_bundle_spec.py
+client/models/v1beta1_counter.py
+client/models/v1beta1_counter_set.py
+client/models/v1beta1_device.py
+client/models/v1beta1_device_allocation_configuration.py
+client/models/v1beta1_device_allocation_result.py
+client/models/v1beta1_device_attribute.py
+client/models/v1beta1_device_capacity.py
+client/models/v1beta1_device_claim.py
+client/models/v1beta1_device_claim_configuration.py
+client/models/v1beta1_device_class.py
+client/models/v1beta1_device_class_configuration.py
+client/models/v1beta1_device_class_list.py
+client/models/v1beta1_device_class_spec.py
+client/models/v1beta1_device_constraint.py
+client/models/v1beta1_device_counter_consumption.py
+client/models/v1beta1_device_request.py
+client/models/v1beta1_device_request_allocation_result.py
+client/models/v1beta1_device_selector.py
+client/models/v1beta1_device_sub_request.py
+client/models/v1beta1_device_taint.py
+client/models/v1beta1_device_toleration.py
+client/models/v1beta1_ip_address.py
+client/models/v1beta1_ip_address_list.py
+client/models/v1beta1_ip_address_spec.py
+client/models/v1beta1_json_patch.py
+client/models/v1beta1_lease_candidate.py
+client/models/v1beta1_lease_candidate_list.py
+client/models/v1beta1_lease_candidate_spec.py
+client/models/v1beta1_match_condition.py
+client/models/v1beta1_match_resources.py
+client/models/v1beta1_mutating_admission_policy.py
+client/models/v1beta1_mutating_admission_policy_binding.py
+client/models/v1beta1_mutating_admission_policy_binding_list.py
+client/models/v1beta1_mutating_admission_policy_binding_spec.py
+client/models/v1beta1_mutating_admission_policy_list.py
+client/models/v1beta1_mutating_admission_policy_spec.py
+client/models/v1beta1_mutation.py
+client/models/v1beta1_named_rule_with_operations.py
+client/models/v1beta1_network_device_data.py
+client/models/v1beta1_opaque_device_configuration.py
+client/models/v1beta1_param_kind.py
+client/models/v1beta1_param_ref.py
+client/models/v1beta1_parent_reference.py
+client/models/v1beta1_pod_certificate_request.py
+client/models/v1beta1_pod_certificate_request_list.py
+client/models/v1beta1_pod_certificate_request_spec.py
+client/models/v1beta1_pod_certificate_request_status.py
+client/models/v1beta1_resource_claim.py
+client/models/v1beta1_resource_claim_consumer_reference.py
+client/models/v1beta1_resource_claim_list.py
+client/models/v1beta1_resource_claim_spec.py
+client/models/v1beta1_resource_claim_status.py
+client/models/v1beta1_resource_claim_template.py
+client/models/v1beta1_resource_claim_template_list.py
+client/models/v1beta1_resource_claim_template_spec.py
+client/models/v1beta1_resource_pool.py
+client/models/v1beta1_resource_slice.py
+client/models/v1beta1_resource_slice_list.py
+client/models/v1beta1_resource_slice_spec.py
+client/models/v1beta1_service_cidr.py
+client/models/v1beta1_service_cidr_list.py
+client/models/v1beta1_service_cidr_spec.py
+client/models/v1beta1_service_cidr_status.py
+client/models/v1beta1_storage_version_migration.py
+client/models/v1beta1_storage_version_migration_list.py
+client/models/v1beta1_storage_version_migration_spec.py
+client/models/v1beta1_storage_version_migration_status.py
+client/models/v1beta1_variable.py
+client/models/v1beta1_volume_attributes_class.py
+client/models/v1beta1_volume_attributes_class_list.py
+client/models/v1beta2_allocated_device_status.py
+client/models/v1beta2_allocation_result.py
+client/models/v1beta2_capacity_request_policy.py
+client/models/v1beta2_capacity_request_policy_range.py
+client/models/v1beta2_capacity_requirements.py
+client/models/v1beta2_cel_device_selector.py
+client/models/v1beta2_counter.py
+client/models/v1beta2_counter_set.py
+client/models/v1beta2_device.py
+client/models/v1beta2_device_allocation_configuration.py
+client/models/v1beta2_device_allocation_result.py
+client/models/v1beta2_device_attribute.py
+client/models/v1beta2_device_capacity.py
+client/models/v1beta2_device_claim.py
+client/models/v1beta2_device_claim_configuration.py
+client/models/v1beta2_device_class.py
+client/models/v1beta2_device_class_configuration.py
+client/models/v1beta2_device_class_list.py
+client/models/v1beta2_device_class_spec.py
+client/models/v1beta2_device_constraint.py
+client/models/v1beta2_device_counter_consumption.py
+client/models/v1beta2_device_request.py
+client/models/v1beta2_device_request_allocation_result.py
+client/models/v1beta2_device_selector.py
+client/models/v1beta2_device_sub_request.py
+client/models/v1beta2_device_taint.py
+client/models/v1beta2_device_toleration.py
+client/models/v1beta2_exact_device_request.py
+client/models/v1beta2_network_device_data.py
+client/models/v1beta2_opaque_device_configuration.py
+client/models/v1beta2_resource_claim.py
+client/models/v1beta2_resource_claim_consumer_reference.py
+client/models/v1beta2_resource_claim_list.py
+client/models/v1beta2_resource_claim_spec.py
+client/models/v1beta2_resource_claim_status.py
+client/models/v1beta2_resource_claim_template.py
+client/models/v1beta2_resource_claim_template_list.py
+client/models/v1beta2_resource_claim_template_spec.py
+client/models/v1beta2_resource_pool.py
+client/models/v1beta2_resource_slice.py
+client/models/v1beta2_resource_slice_list.py
+client/models/v1beta2_resource_slice_spec.py
+client/models/v2_api_group_discovery.py
+client/models/v2_api_group_discovery_list.py
+client/models/v2_api_resource_discovery.py
+client/models/v2_api_subresource_discovery.py
+client/models/v2_api_version_discovery.py
+client/models/v2_container_resource_metric_source.py
+client/models/v2_container_resource_metric_status.py
+client/models/v2_cross_version_object_reference.py
+client/models/v2_external_metric_source.py
+client/models/v2_external_metric_status.py
+client/models/v2_horizontal_pod_autoscaler.py
+client/models/v2_horizontal_pod_autoscaler_behavior.py
+client/models/v2_horizontal_pod_autoscaler_condition.py
+client/models/v2_horizontal_pod_autoscaler_list.py
+client/models/v2_horizontal_pod_autoscaler_spec.py
+client/models/v2_horizontal_pod_autoscaler_status.py
+client/models/v2_hpa_scaling_policy.py
+client/models/v2_hpa_scaling_rules.py
+client/models/v2_metric_identifier.py
+client/models/v2_metric_spec.py
+client/models/v2_metric_status.py
+client/models/v2_metric_target.py
+client/models/v2_metric_value_status.py
+client/models/v2_object_metric_source.py
+client/models/v2_object_metric_status.py
+client/models/v2_pods_metric_source.py
+client/models/v2_pods_metric_status.py
+client/models/v2_resource_metric_source.py
+client/models/v2_resource_metric_status.py
+client/models/v2beta1_api_group_discovery.py
+client/models/v2beta1_api_group_discovery_list.py
+client/models/v2beta1_api_resource_discovery.py
+client/models/v2beta1_api_subresource_discovery.py
+client/models/v2beta1_api_version_discovery.py
+client/models/version_info.py
+client/rest.py
+docs/AdmissionregistrationApi.md
+docs/AdmissionregistrationV1Api.md
+docs/AdmissionregistrationV1ServiceReference.md
+docs/AdmissionregistrationV1WebhookClientConfig.md
+docs/AdmissionregistrationV1alpha1Api.md
+docs/AdmissionregistrationV1beta1Api.md
+docs/ApiextensionsApi.md
+docs/ApiextensionsV1Api.md
+docs/ApiextensionsV1ServiceReference.md
+docs/ApiextensionsV1WebhookClientConfig.md
+docs/ApiregistrationApi.md
+docs/ApiregistrationV1Api.md
+docs/ApiregistrationV1ServiceReference.md
+docs/ApisApi.md
+docs/AppsApi.md
+docs/AppsV1Api.md
+docs/AuthenticationApi.md
+docs/AuthenticationV1Api.md
+docs/AuthenticationV1TokenRequest.md
+docs/AuthorizationApi.md
+docs/AuthorizationV1Api.md
+docs/AutoscalingApi.md
+docs/AutoscalingV1Api.md
+docs/AutoscalingV2Api.md
+docs/BatchApi.md
+docs/BatchV1Api.md
+docs/CertificatesApi.md
+docs/CertificatesV1Api.md
+docs/CertificatesV1alpha1Api.md
+docs/CertificatesV1beta1Api.md
+docs/CoordinationApi.md
+docs/CoordinationV1Api.md
+docs/CoordinationV1alpha2Api.md
+docs/CoordinationV1beta1Api.md
+docs/CoreApi.md
+docs/CoreV1Api.md
+docs/CoreV1EndpointPort.md
+docs/CoreV1Event.md
+docs/CoreV1EventList.md
+docs/CoreV1EventSeries.md
+docs/CoreV1ResourceClaim.md
+docs/CustomObjectsApi.md
+docs/DiscoveryApi.md
+docs/DiscoveryV1Api.md
+docs/DiscoveryV1EndpointPort.md
+docs/EventsApi.md
+docs/EventsV1Api.md
+docs/EventsV1Event.md
+docs/EventsV1EventList.md
+docs/EventsV1EventSeries.md
+docs/FlowcontrolApiserverApi.md
+docs/FlowcontrolApiserverV1Api.md
+docs/FlowcontrolV1Subject.md
+docs/InternalApiserverApi.md
+docs/InternalApiserverV1alpha1Api.md
+docs/LogsApi.md
+docs/NetworkingApi.md
+docs/NetworkingV1Api.md
+docs/NetworkingV1beta1Api.md
+docs/NodeApi.md
+docs/NodeV1Api.md
+docs/OpenidApi.md
+docs/PolicyApi.md
+docs/PolicyV1Api.md
+docs/RbacAuthorizationApi.md
+docs/RbacAuthorizationV1Api.md
+docs/RbacV1Subject.md
+docs/ResourceApi.md
+docs/ResourceV1Api.md
+docs/ResourceV1ResourceClaim.md
+docs/ResourceV1alpha3Api.md
+docs/ResourceV1beta1Api.md
+docs/ResourceV1beta2Api.md
+docs/SchedulingApi.md
+docs/SchedulingV1Api.md
+docs/SchedulingV1alpha1Api.md
+docs/StorageApi.md
+docs/StorageV1Api.md
+docs/StorageV1TokenRequest.md
+docs/StorageV1beta1Api.md
+docs/StoragemigrationApi.md
+docs/StoragemigrationV1beta1Api.md
+docs/V1APIGroup.md
+docs/V1APIGroupList.md
+docs/V1APIResource.md
+docs/V1APIResourceList.md
+docs/V1APIService.md
+docs/V1APIServiceCondition.md
+docs/V1APIServiceList.md
+docs/V1APIServiceSpec.md
+docs/V1APIServiceStatus.md
+docs/V1APIVersions.md
+docs/V1AWSElasticBlockStoreVolumeSource.md
+docs/V1Affinity.md
+docs/V1AggregationRule.md
+docs/V1AllocatedDeviceStatus.md
+docs/V1AllocationResult.md
+docs/V1AppArmorProfile.md
+docs/V1AttachedVolume.md
+docs/V1AuditAnnotation.md
+docs/V1AzureDiskVolumeSource.md
+docs/V1AzureFilePersistentVolumeSource.md
+docs/V1AzureFileVolumeSource.md
+docs/V1Binding.md
+docs/V1BoundObjectReference.md
+docs/V1CELDeviceSelector.md
+docs/V1CSIDriver.md
+docs/V1CSIDriverList.md
+docs/V1CSIDriverSpec.md
+docs/V1CSINode.md
+docs/V1CSINodeDriver.md
+docs/V1CSINodeList.md
+docs/V1CSINodeSpec.md
+docs/V1CSIPersistentVolumeSource.md
+docs/V1CSIStorageCapacity.md
+docs/V1CSIStorageCapacityList.md
+docs/V1CSIVolumeSource.md
+docs/V1Capabilities.md
+docs/V1CapacityRequestPolicy.md
+docs/V1CapacityRequestPolicyRange.md
+docs/V1CapacityRequirements.md
+docs/V1CephFSPersistentVolumeSource.md
+docs/V1CephFSVolumeSource.md
+docs/V1CertificateSigningRequest.md
+docs/V1CertificateSigningRequestCondition.md
+docs/V1CertificateSigningRequestList.md
+docs/V1CertificateSigningRequestSpec.md
+docs/V1CertificateSigningRequestStatus.md
+docs/V1CinderPersistentVolumeSource.md
+docs/V1CinderVolumeSource.md
+docs/V1ClientIPConfig.md
+docs/V1ClusterRole.md
+docs/V1ClusterRoleBinding.md
+docs/V1ClusterRoleBindingList.md
+docs/V1ClusterRoleList.md
+docs/V1ClusterTrustBundleProjection.md
+docs/V1ComponentCondition.md
+docs/V1ComponentStatus.md
+docs/V1ComponentStatusList.md
+docs/V1Condition.md
+docs/V1ConfigMap.md
+docs/V1ConfigMapEnvSource.md
+docs/V1ConfigMapKeySelector.md
+docs/V1ConfigMapList.md
+docs/V1ConfigMapNodeConfigSource.md
+docs/V1ConfigMapProjection.md
+docs/V1ConfigMapVolumeSource.md
+docs/V1Container.md
+docs/V1ContainerExtendedResourceRequest.md
+docs/V1ContainerImage.md
+docs/V1ContainerPort.md
+docs/V1ContainerResizePolicy.md
+docs/V1ContainerRestartRule.md
+docs/V1ContainerRestartRuleOnExitCodes.md
+docs/V1ContainerState.md
+docs/V1ContainerStateRunning.md
+docs/V1ContainerStateTerminated.md
+docs/V1ContainerStateWaiting.md
+docs/V1ContainerStatus.md
+docs/V1ContainerUser.md
+docs/V1ControllerRevision.md
+docs/V1ControllerRevisionList.md
+docs/V1Counter.md
+docs/V1CounterSet.md
+docs/V1CronJob.md
+docs/V1CronJobList.md
+docs/V1CronJobSpec.md
+docs/V1CronJobStatus.md
+docs/V1CrossVersionObjectReference.md
+docs/V1CustomResourceColumnDefinition.md
+docs/V1CustomResourceConversion.md
+docs/V1CustomResourceDefinition.md
+docs/V1CustomResourceDefinitionCondition.md
+docs/V1CustomResourceDefinitionList.md
+docs/V1CustomResourceDefinitionNames.md
+docs/V1CustomResourceDefinitionSpec.md
+docs/V1CustomResourceDefinitionStatus.md
+docs/V1CustomResourceDefinitionVersion.md
+docs/V1CustomResourceSubresourceScale.md
+docs/V1CustomResourceSubresources.md
+docs/V1CustomResourceValidation.md
+docs/V1DaemonEndpoint.md
+docs/V1DaemonSet.md
+docs/V1DaemonSetCondition.md
+docs/V1DaemonSetList.md
+docs/V1DaemonSetSpec.md
+docs/V1DaemonSetStatus.md
+docs/V1DaemonSetUpdateStrategy.md
+docs/V1DeleteOptions.md
+docs/V1Deployment.md
+docs/V1DeploymentCondition.md
+docs/V1DeploymentList.md
+docs/V1DeploymentSpec.md
+docs/V1DeploymentStatus.md
+docs/V1DeploymentStrategy.md
+docs/V1Device.md
+docs/V1DeviceAllocationConfiguration.md
+docs/V1DeviceAllocationResult.md
+docs/V1DeviceAttribute.md
+docs/V1DeviceCapacity.md
+docs/V1DeviceClaim.md
+docs/V1DeviceClaimConfiguration.md
+docs/V1DeviceClass.md
+docs/V1DeviceClassConfiguration.md
+docs/V1DeviceClassList.md
+docs/V1DeviceClassSpec.md
+docs/V1DeviceConstraint.md
+docs/V1DeviceCounterConsumption.md
+docs/V1DeviceRequest.md
+docs/V1DeviceRequestAllocationResult.md
+docs/V1DeviceSelector.md
+docs/V1DeviceSubRequest.md
+docs/V1DeviceTaint.md
+docs/V1DeviceToleration.md
+docs/V1DownwardAPIProjection.md
+docs/V1DownwardAPIVolumeFile.md
+docs/V1DownwardAPIVolumeSource.md
+docs/V1EmptyDirVolumeSource.md
+docs/V1Endpoint.md
+docs/V1EndpointAddress.md
+docs/V1EndpointConditions.md
+docs/V1EndpointHints.md
+docs/V1EndpointSlice.md
+docs/V1EndpointSliceList.md
+docs/V1EndpointSubset.md
+docs/V1Endpoints.md
+docs/V1EndpointsList.md
+docs/V1EnvFromSource.md
+docs/V1EnvVar.md
+docs/V1EnvVarSource.md
+docs/V1EphemeralContainer.md
+docs/V1EphemeralVolumeSource.md
+docs/V1EventSource.md
+docs/V1Eviction.md
+docs/V1ExactDeviceRequest.md
+docs/V1ExecAction.md
+docs/V1ExemptPriorityLevelConfiguration.md
+docs/V1ExpressionWarning.md
+docs/V1ExternalDocumentation.md
+docs/V1FCVolumeSource.md
+docs/V1FieldSelectorAttributes.md
+docs/V1FieldSelectorRequirement.md
+docs/V1FileKeySelector.md
+docs/V1FlexPersistentVolumeSource.md
+docs/V1FlexVolumeSource.md
+docs/V1FlockerVolumeSource.md
+docs/V1FlowDistinguisherMethod.md
+docs/V1FlowSchema.md
+docs/V1FlowSchemaCondition.md
+docs/V1FlowSchemaList.md
+docs/V1FlowSchemaSpec.md
+docs/V1FlowSchemaStatus.md
+docs/V1ForNode.md
+docs/V1ForZone.md
+docs/V1GCEPersistentDiskVolumeSource.md
+docs/V1GRPCAction.md
+docs/V1GitRepoVolumeSource.md
+docs/V1GlusterfsPersistentVolumeSource.md
+docs/V1GlusterfsVolumeSource.md
+docs/V1GroupResource.md
+docs/V1GroupSubject.md
+docs/V1GroupVersionForDiscovery.md
+docs/V1HTTPGetAction.md
+docs/V1HTTPHeader.md
+docs/V1HTTPIngressPath.md
+docs/V1HTTPIngressRuleValue.md
+docs/V1HorizontalPodAutoscaler.md
+docs/V1HorizontalPodAutoscalerList.md
+docs/V1HorizontalPodAutoscalerSpec.md
+docs/V1HorizontalPodAutoscalerStatus.md
+docs/V1HostAlias.md
+docs/V1HostIP.md
+docs/V1HostPathVolumeSource.md
+docs/V1IPAddress.md
+docs/V1IPAddressList.md
+docs/V1IPAddressSpec.md
+docs/V1IPBlock.md
+docs/V1ISCSIPersistentVolumeSource.md
+docs/V1ISCSIVolumeSource.md
+docs/V1ImageVolumeSource.md
+docs/V1Ingress.md
+docs/V1IngressBackend.md
+docs/V1IngressClass.md
+docs/V1IngressClassList.md
+docs/V1IngressClassParametersReference.md
+docs/V1IngressClassSpec.md
+docs/V1IngressList.md
+docs/V1IngressLoadBalancerIngress.md
+docs/V1IngressLoadBalancerStatus.md
+docs/V1IngressPortStatus.md
+docs/V1IngressRule.md
+docs/V1IngressServiceBackend.md
+docs/V1IngressSpec.md
+docs/V1IngressStatus.md
+docs/V1IngressTLS.md
+docs/V1JSONSchemaProps.md
+docs/V1Job.md
+docs/V1JobCondition.md
+docs/V1JobList.md
+docs/V1JobSpec.md
+docs/V1JobStatus.md
+docs/V1JobTemplateSpec.md
+docs/V1KeyToPath.md
+docs/V1LabelSelector.md
+docs/V1LabelSelectorAttributes.md
+docs/V1LabelSelectorRequirement.md
+docs/V1Lease.md
+docs/V1LeaseList.md
+docs/V1LeaseSpec.md
+docs/V1Lifecycle.md
+docs/V1LifecycleHandler.md
+docs/V1LimitRange.md
+docs/V1LimitRangeItem.md
+docs/V1LimitRangeList.md
+docs/V1LimitRangeSpec.md
+docs/V1LimitResponse.md
+docs/V1LimitedPriorityLevelConfiguration.md
+docs/V1LinuxContainerUser.md
+docs/V1ListMeta.md
+docs/V1LoadBalancerIngress.md
+docs/V1LoadBalancerStatus.md
+docs/V1LocalObjectReference.md
+docs/V1LocalSubjectAccessReview.md
+docs/V1LocalVolumeSource.md
+docs/V1ManagedFieldsEntry.md
+docs/V1MatchCondition.md
+docs/V1MatchResources.md
+docs/V1ModifyVolumeStatus.md
+docs/V1MutatingWebhook.md
+docs/V1MutatingWebhookConfiguration.md
+docs/V1MutatingWebhookConfigurationList.md
+docs/V1NFSVolumeSource.md
+docs/V1NamedRuleWithOperations.md
+docs/V1Namespace.md
+docs/V1NamespaceCondition.md
+docs/V1NamespaceList.md
+docs/V1NamespaceSpec.md
+docs/V1NamespaceStatus.md
+docs/V1NetworkDeviceData.md
+docs/V1NetworkPolicy.md
+docs/V1NetworkPolicyEgressRule.md
+docs/V1NetworkPolicyIngressRule.md
+docs/V1NetworkPolicyList.md
+docs/V1NetworkPolicyPeer.md
+docs/V1NetworkPolicyPort.md
+docs/V1NetworkPolicySpec.md
+docs/V1Node.md
+docs/V1NodeAddress.md
+docs/V1NodeAffinity.md
+docs/V1NodeCondition.md
+docs/V1NodeConfigSource.md
+docs/V1NodeConfigStatus.md
+docs/V1NodeDaemonEndpoints.md
+docs/V1NodeFeatures.md
+docs/V1NodeList.md
+docs/V1NodeRuntimeHandler.md
+docs/V1NodeRuntimeHandlerFeatures.md
+docs/V1NodeSelector.md
+docs/V1NodeSelectorRequirement.md
+docs/V1NodeSelectorTerm.md
+docs/V1NodeSpec.md
+docs/V1NodeStatus.md
+docs/V1NodeSwapStatus.md
+docs/V1NodeSystemInfo.md
+docs/V1NonResourceAttributes.md
+docs/V1NonResourcePolicyRule.md
+docs/V1NonResourceRule.md
+docs/V1ObjectFieldSelector.md
+docs/V1ObjectMeta.md
+docs/V1ObjectReference.md
+docs/V1OpaqueDeviceConfiguration.md
+docs/V1Overhead.md
+docs/V1OwnerReference.md
+docs/V1ParamKind.md
+docs/V1ParamRef.md
+docs/V1ParentReference.md
+docs/V1PersistentVolume.md
+docs/V1PersistentVolumeClaim.md
+docs/V1PersistentVolumeClaimCondition.md
+docs/V1PersistentVolumeClaimList.md
+docs/V1PersistentVolumeClaimSpec.md
+docs/V1PersistentVolumeClaimStatus.md
+docs/V1PersistentVolumeClaimTemplate.md
+docs/V1PersistentVolumeClaimVolumeSource.md
+docs/V1PersistentVolumeList.md
+docs/V1PersistentVolumeSpec.md
+docs/V1PersistentVolumeStatus.md
+docs/V1PhotonPersistentDiskVolumeSource.md
+docs/V1Pod.md
+docs/V1PodAffinity.md
+docs/V1PodAffinityTerm.md
+docs/V1PodAntiAffinity.md
+docs/V1PodCertificateProjection.md
+docs/V1PodCondition.md
+docs/V1PodDNSConfig.md
+docs/V1PodDNSConfigOption.md
+docs/V1PodDisruptionBudget.md
+docs/V1PodDisruptionBudgetList.md
+docs/V1PodDisruptionBudgetSpec.md
+docs/V1PodDisruptionBudgetStatus.md
+docs/V1PodExtendedResourceClaimStatus.md
+docs/V1PodFailurePolicy.md
+docs/V1PodFailurePolicyOnExitCodesRequirement.md
+docs/V1PodFailurePolicyOnPodConditionsPattern.md
+docs/V1PodFailurePolicyRule.md
+docs/V1PodIP.md
+docs/V1PodList.md
+docs/V1PodOS.md
+docs/V1PodReadinessGate.md
+docs/V1PodResourceClaim.md
+docs/V1PodResourceClaimStatus.md
+docs/V1PodSchedulingGate.md
+docs/V1PodSecurityContext.md
+docs/V1PodSpec.md
+docs/V1PodStatus.md
+docs/V1PodTemplate.md
+docs/V1PodTemplateList.md
+docs/V1PodTemplateSpec.md
+docs/V1PolicyRule.md
+docs/V1PolicyRulesWithSubjects.md
+docs/V1PortStatus.md
+docs/V1PortworxVolumeSource.md
+docs/V1Preconditions.md
+docs/V1PreferredSchedulingTerm.md
+docs/V1PriorityClass.md
+docs/V1PriorityClassList.md
+docs/V1PriorityLevelConfiguration.md
+docs/V1PriorityLevelConfigurationCondition.md
+docs/V1PriorityLevelConfigurationList.md
+docs/V1PriorityLevelConfigurationReference.md
+docs/V1PriorityLevelConfigurationSpec.md
+docs/V1PriorityLevelConfigurationStatus.md
+docs/V1Probe.md
+docs/V1ProjectedVolumeSource.md
+docs/V1QueuingConfiguration.md
+docs/V1QuobyteVolumeSource.md
+docs/V1RBDPersistentVolumeSource.md
+docs/V1RBDVolumeSource.md
+docs/V1ReplicaSet.md
+docs/V1ReplicaSetCondition.md
+docs/V1ReplicaSetList.md
+docs/V1ReplicaSetSpec.md
+docs/V1ReplicaSetStatus.md
+docs/V1ReplicationController.md
+docs/V1ReplicationControllerCondition.md
+docs/V1ReplicationControllerList.md
+docs/V1ReplicationControllerSpec.md
+docs/V1ReplicationControllerStatus.md
+docs/V1ResourceAttributes.md
+docs/V1ResourceClaimConsumerReference.md
+docs/V1ResourceClaimList.md
+docs/V1ResourceClaimSpec.md
+docs/V1ResourceClaimStatus.md
+docs/V1ResourceClaimTemplate.md
+docs/V1ResourceClaimTemplateList.md
+docs/V1ResourceClaimTemplateSpec.md
+docs/V1ResourceFieldSelector.md
+docs/V1ResourceHealth.md
+docs/V1ResourcePolicyRule.md
+docs/V1ResourcePool.md
+docs/V1ResourceQuota.md
+docs/V1ResourceQuotaList.md
+docs/V1ResourceQuotaSpec.md
+docs/V1ResourceQuotaStatus.md
+docs/V1ResourceRequirements.md
+docs/V1ResourceRule.md
+docs/V1ResourceSlice.md
+docs/V1ResourceSliceList.md
+docs/V1ResourceSliceSpec.md
+docs/V1ResourceStatus.md
+docs/V1Role.md
+docs/V1RoleBinding.md
+docs/V1RoleBindingList.md
+docs/V1RoleList.md
+docs/V1RoleRef.md
+docs/V1RollingUpdateDaemonSet.md
+docs/V1RollingUpdateDeployment.md
+docs/V1RollingUpdateStatefulSetStrategy.md
+docs/V1RuleWithOperations.md
+docs/V1RuntimeClass.md
+docs/V1RuntimeClassList.md
+docs/V1SELinuxOptions.md
+docs/V1Scale.md
+docs/V1ScaleIOPersistentVolumeSource.md
+docs/V1ScaleIOVolumeSource.md
+docs/V1ScaleSpec.md
+docs/V1ScaleStatus.md
+docs/V1Scheduling.md
+docs/V1ScopeSelector.md
+docs/V1ScopedResourceSelectorRequirement.md
+docs/V1SeccompProfile.md
+docs/V1Secret.md
+docs/V1SecretEnvSource.md
+docs/V1SecretKeySelector.md
+docs/V1SecretList.md
+docs/V1SecretProjection.md
+docs/V1SecretReference.md
+docs/V1SecretVolumeSource.md
+docs/V1SecurityContext.md
+docs/V1SelectableField.md
+docs/V1SelfSubjectAccessReview.md
+docs/V1SelfSubjectAccessReviewSpec.md
+docs/V1SelfSubjectReview.md
+docs/V1SelfSubjectReviewStatus.md
+docs/V1SelfSubjectRulesReview.md
+docs/V1SelfSubjectRulesReviewSpec.md
+docs/V1ServerAddressByClientCIDR.md
+docs/V1Service.md
+docs/V1ServiceAccount.md
+docs/V1ServiceAccountList.md
+docs/V1ServiceAccountSubject.md
+docs/V1ServiceAccountTokenProjection.md
+docs/V1ServiceBackendPort.md
+docs/V1ServiceCIDR.md
+docs/V1ServiceCIDRList.md
+docs/V1ServiceCIDRSpec.md
+docs/V1ServiceCIDRStatus.md
+docs/V1ServiceList.md
+docs/V1ServicePort.md
+docs/V1ServiceSpec.md
+docs/V1ServiceStatus.md
+docs/V1SessionAffinityConfig.md
+docs/V1SleepAction.md
+docs/V1StatefulSet.md
+docs/V1StatefulSetCondition.md
+docs/V1StatefulSetList.md
+docs/V1StatefulSetOrdinals.md
+docs/V1StatefulSetPersistentVolumeClaimRetentionPolicy.md
+docs/V1StatefulSetSpec.md
+docs/V1StatefulSetStatus.md
+docs/V1StatefulSetUpdateStrategy.md
+docs/V1Status.md
+docs/V1StatusCause.md
+docs/V1StatusDetails.md
+docs/V1StorageClass.md
+docs/V1StorageClassList.md
+docs/V1StorageOSPersistentVolumeSource.md
+docs/V1StorageOSVolumeSource.md
+docs/V1SubjectAccessReview.md
+docs/V1SubjectAccessReviewSpec.md
+docs/V1SubjectAccessReviewStatus.md
+docs/V1SubjectRulesReviewStatus.md
+docs/V1SuccessPolicy.md
+docs/V1SuccessPolicyRule.md
+docs/V1Sysctl.md
+docs/V1TCPSocketAction.md
+docs/V1Taint.md
+docs/V1TokenRequestSpec.md
+docs/V1TokenRequestStatus.md
+docs/V1TokenReview.md
+docs/V1TokenReviewSpec.md
+docs/V1TokenReviewStatus.md
+docs/V1Toleration.md
+docs/V1TopologySelectorLabelRequirement.md
+docs/V1TopologySelectorTerm.md
+docs/V1TopologySpreadConstraint.md
+docs/V1TypeChecking.md
+docs/V1TypedLocalObjectReference.md
+docs/V1TypedObjectReference.md
+docs/V1UncountedTerminatedPods.md
+docs/V1UserInfo.md
+docs/V1UserSubject.md
+docs/V1ValidatingAdmissionPolicy.md
+docs/V1ValidatingAdmissionPolicyBinding.md
+docs/V1ValidatingAdmissionPolicyBindingList.md
+docs/V1ValidatingAdmissionPolicyBindingSpec.md
+docs/V1ValidatingAdmissionPolicyList.md
+docs/V1ValidatingAdmissionPolicySpec.md
+docs/V1ValidatingAdmissionPolicyStatus.md
+docs/V1ValidatingWebhook.md
+docs/V1ValidatingWebhookConfiguration.md
+docs/V1ValidatingWebhookConfigurationList.md
+docs/V1Validation.md
+docs/V1ValidationRule.md
+docs/V1Variable.md
+docs/V1Volume.md
+docs/V1VolumeAttachment.md
+docs/V1VolumeAttachmentList.md
+docs/V1VolumeAttachmentSource.md
+docs/V1VolumeAttachmentSpec.md
+docs/V1VolumeAttachmentStatus.md
+docs/V1VolumeAttributesClass.md
+docs/V1VolumeAttributesClassList.md
+docs/V1VolumeDevice.md
+docs/V1VolumeError.md
+docs/V1VolumeMount.md
+docs/V1VolumeMountStatus.md
+docs/V1VolumeNodeAffinity.md
+docs/V1VolumeNodeResources.md
+docs/V1VolumeProjection.md
+docs/V1VolumeResourceRequirements.md
+docs/V1VsphereVirtualDiskVolumeSource.md
+docs/V1WatchEvent.md
+docs/V1WebhookConversion.md
+docs/V1WeightedPodAffinityTerm.md
+docs/V1WindowsSecurityContextOptions.md
+docs/V1WorkloadReference.md
+docs/V1alpha1ApplyConfiguration.md
+docs/V1alpha1ClusterTrustBundle.md
+docs/V1alpha1ClusterTrustBundleList.md
+docs/V1alpha1ClusterTrustBundleSpec.md
+docs/V1alpha1GangSchedulingPolicy.md
+docs/V1alpha1JSONPatch.md
+docs/V1alpha1MatchCondition.md
+docs/V1alpha1MatchResources.md
+docs/V1alpha1MutatingAdmissionPolicy.md
+docs/V1alpha1MutatingAdmissionPolicyBinding.md
+docs/V1alpha1MutatingAdmissionPolicyBindingList.md
+docs/V1alpha1MutatingAdmissionPolicyBindingSpec.md
+docs/V1alpha1MutatingAdmissionPolicyList.md
+docs/V1alpha1MutatingAdmissionPolicySpec.md
+docs/V1alpha1Mutation.md
+docs/V1alpha1NamedRuleWithOperations.md
+docs/V1alpha1ParamKind.md
+docs/V1alpha1ParamRef.md
+docs/V1alpha1PodGroup.md
+docs/V1alpha1PodGroupPolicy.md
+docs/V1alpha1ServerStorageVersion.md
+docs/V1alpha1StorageVersion.md
+docs/V1alpha1StorageVersionCondition.md
+docs/V1alpha1StorageVersionList.md
+docs/V1alpha1StorageVersionStatus.md
+docs/V1alpha1TypedLocalObjectReference.md
+docs/V1alpha1Variable.md
+docs/V1alpha1Workload.md
+docs/V1alpha1WorkloadList.md
+docs/V1alpha1WorkloadSpec.md
+docs/V1alpha2LeaseCandidate.md
+docs/V1alpha2LeaseCandidateList.md
+docs/V1alpha2LeaseCandidateSpec.md
+docs/V1alpha3DeviceTaint.md
+docs/V1alpha3DeviceTaintRule.md
+docs/V1alpha3DeviceTaintRuleList.md
+docs/V1alpha3DeviceTaintRuleSpec.md
+docs/V1alpha3DeviceTaintRuleStatus.md
+docs/V1alpha3DeviceTaintSelector.md
+docs/V1beta1AllocatedDeviceStatus.md
+docs/V1beta1AllocationResult.md
+docs/V1beta1ApplyConfiguration.md
+docs/V1beta1BasicDevice.md
+docs/V1beta1CELDeviceSelector.md
+docs/V1beta1CapacityRequestPolicy.md
+docs/V1beta1CapacityRequestPolicyRange.md
+docs/V1beta1CapacityRequirements.md
+docs/V1beta1ClusterTrustBundle.md
+docs/V1beta1ClusterTrustBundleList.md
+docs/V1beta1ClusterTrustBundleSpec.md
+docs/V1beta1Counter.md
+docs/V1beta1CounterSet.md
+docs/V1beta1Device.md
+docs/V1beta1DeviceAllocationConfiguration.md
+docs/V1beta1DeviceAllocationResult.md
+docs/V1beta1DeviceAttribute.md
+docs/V1beta1DeviceCapacity.md
+docs/V1beta1DeviceClaim.md
+docs/V1beta1DeviceClaimConfiguration.md
+docs/V1beta1DeviceClass.md
+docs/V1beta1DeviceClassConfiguration.md
+docs/V1beta1DeviceClassList.md
+docs/V1beta1DeviceClassSpec.md
+docs/V1beta1DeviceConstraint.md
+docs/V1beta1DeviceCounterConsumption.md
+docs/V1beta1DeviceRequest.md
+docs/V1beta1DeviceRequestAllocationResult.md
+docs/V1beta1DeviceSelector.md
+docs/V1beta1DeviceSubRequest.md
+docs/V1beta1DeviceTaint.md
+docs/V1beta1DeviceToleration.md
+docs/V1beta1IPAddress.md
+docs/V1beta1IPAddressList.md
+docs/V1beta1IPAddressSpec.md
+docs/V1beta1JSONPatch.md
+docs/V1beta1LeaseCandidate.md
+docs/V1beta1LeaseCandidateList.md
+docs/V1beta1LeaseCandidateSpec.md
+docs/V1beta1MatchCondition.md
+docs/V1beta1MatchResources.md
+docs/V1beta1MutatingAdmissionPolicy.md
+docs/V1beta1MutatingAdmissionPolicyBinding.md
+docs/V1beta1MutatingAdmissionPolicyBindingList.md
+docs/V1beta1MutatingAdmissionPolicyBindingSpec.md
+docs/V1beta1MutatingAdmissionPolicyList.md
+docs/V1beta1MutatingAdmissionPolicySpec.md
+docs/V1beta1Mutation.md
+docs/V1beta1NamedRuleWithOperations.md
+docs/V1beta1NetworkDeviceData.md
+docs/V1beta1OpaqueDeviceConfiguration.md
+docs/V1beta1ParamKind.md
+docs/V1beta1ParamRef.md
+docs/V1beta1ParentReference.md
+docs/V1beta1PodCertificateRequest.md
+docs/V1beta1PodCertificateRequestList.md
+docs/V1beta1PodCertificateRequestSpec.md
+docs/V1beta1PodCertificateRequestStatus.md
+docs/V1beta1ResourceClaim.md
+docs/V1beta1ResourceClaimConsumerReference.md
+docs/V1beta1ResourceClaimList.md
+docs/V1beta1ResourceClaimSpec.md
+docs/V1beta1ResourceClaimStatus.md
+docs/V1beta1ResourceClaimTemplate.md
+docs/V1beta1ResourceClaimTemplateList.md
+docs/V1beta1ResourceClaimTemplateSpec.md
+docs/V1beta1ResourcePool.md
+docs/V1beta1ResourceSlice.md
+docs/V1beta1ResourceSliceList.md
+docs/V1beta1ResourceSliceSpec.md
+docs/V1beta1ServiceCIDR.md
+docs/V1beta1ServiceCIDRList.md
+docs/V1beta1ServiceCIDRSpec.md
+docs/V1beta1ServiceCIDRStatus.md
+docs/V1beta1StorageVersionMigration.md
+docs/V1beta1StorageVersionMigrationList.md
+docs/V1beta1StorageVersionMigrationSpec.md
+docs/V1beta1StorageVersionMigrationStatus.md
+docs/V1beta1Variable.md
+docs/V1beta1VolumeAttributesClass.md
+docs/V1beta1VolumeAttributesClassList.md
+docs/V1beta2AllocatedDeviceStatus.md
+docs/V1beta2AllocationResult.md
+docs/V1beta2CELDeviceSelector.md
+docs/V1beta2CapacityRequestPolicy.md
+docs/V1beta2CapacityRequestPolicyRange.md
+docs/V1beta2CapacityRequirements.md
+docs/V1beta2Counter.md
+docs/V1beta2CounterSet.md
+docs/V1beta2Device.md
+docs/V1beta2DeviceAllocationConfiguration.md
+docs/V1beta2DeviceAllocationResult.md
+docs/V1beta2DeviceAttribute.md
+docs/V1beta2DeviceCapacity.md
+docs/V1beta2DeviceClaim.md
+docs/V1beta2DeviceClaimConfiguration.md
+docs/V1beta2DeviceClass.md
+docs/V1beta2DeviceClassConfiguration.md
+docs/V1beta2DeviceClassList.md
+docs/V1beta2DeviceClassSpec.md
+docs/V1beta2DeviceConstraint.md
+docs/V1beta2DeviceCounterConsumption.md
+docs/V1beta2DeviceRequest.md
+docs/V1beta2DeviceRequestAllocationResult.md
+docs/V1beta2DeviceSelector.md
+docs/V1beta2DeviceSubRequest.md
+docs/V1beta2DeviceTaint.md
+docs/V1beta2DeviceToleration.md
+docs/V1beta2ExactDeviceRequest.md
+docs/V1beta2NetworkDeviceData.md
+docs/V1beta2OpaqueDeviceConfiguration.md
+docs/V1beta2ResourceClaim.md
+docs/V1beta2ResourceClaimConsumerReference.md
+docs/V1beta2ResourceClaimList.md
+docs/V1beta2ResourceClaimSpec.md
+docs/V1beta2ResourceClaimStatus.md
+docs/V1beta2ResourceClaimTemplate.md
+docs/V1beta2ResourceClaimTemplateList.md
+docs/V1beta2ResourceClaimTemplateSpec.md
+docs/V1beta2ResourcePool.md
+docs/V1beta2ResourceSlice.md
+docs/V1beta2ResourceSliceList.md
+docs/V1beta2ResourceSliceSpec.md
+docs/V2APIGroupDiscovery.md
+docs/V2APIGroupDiscoveryList.md
+docs/V2APIResourceDiscovery.md
+docs/V2APISubresourceDiscovery.md
+docs/V2APIVersionDiscovery.md
+docs/V2ContainerResourceMetricSource.md
+docs/V2ContainerResourceMetricStatus.md
+docs/V2CrossVersionObjectReference.md
+docs/V2ExternalMetricSource.md
+docs/V2ExternalMetricStatus.md
+docs/V2HPAScalingPolicy.md
+docs/V2HPAScalingRules.md
+docs/V2HorizontalPodAutoscaler.md
+docs/V2HorizontalPodAutoscalerBehavior.md
+docs/V2HorizontalPodAutoscalerCondition.md
+docs/V2HorizontalPodAutoscalerList.md
+docs/V2HorizontalPodAutoscalerSpec.md
+docs/V2HorizontalPodAutoscalerStatus.md
+docs/V2MetricIdentifier.md
+docs/V2MetricSpec.md
+docs/V2MetricStatus.md
+docs/V2MetricTarget.md
+docs/V2MetricValueStatus.md
+docs/V2ObjectMetricSource.md
+docs/V2ObjectMetricStatus.md
+docs/V2PodsMetricSource.md
+docs/V2PodsMetricStatus.md
+docs/V2ResourceMetricSource.md
+docs/V2ResourceMetricStatus.md
+docs/V2beta1APIGroupDiscovery.md
+docs/V2beta1APIGroupDiscoveryList.md
+docs/V2beta1APIResourceDiscovery.md
+docs/V2beta1APISubresourceDiscovery.md
+docs/V2beta1APIVersionDiscovery.md
+docs/VersionApi.md
+docs/VersionInfo.md
+docs/WellKnownApi.md
+setup.cfg
+test/__init__.py
+test/test_admissionregistration_api.py
+test/test_admissionregistration_v1_api.py
+test/test_admissionregistration_v1_service_reference.py
+test/test_admissionregistration_v1_webhook_client_config.py
+test/test_admissionregistration_v1alpha1_api.py
+test/test_admissionregistration_v1beta1_api.py
+test/test_apiextensions_api.py
+test/test_apiextensions_v1_api.py
+test/test_apiextensions_v1_service_reference.py
+test/test_apiextensions_v1_webhook_client_config.py
+test/test_apiregistration_api.py
+test/test_apiregistration_v1_api.py
+test/test_apiregistration_v1_service_reference.py
+test/test_apis_api.py
+test/test_apps_api.py
+test/test_apps_v1_api.py
+test/test_authentication_api.py
+test/test_authentication_v1_api.py
+test/test_authentication_v1_token_request.py
+test/test_authorization_api.py
+test/test_authorization_v1_api.py
+test/test_autoscaling_api.py
+test/test_autoscaling_v1_api.py
+test/test_autoscaling_v2_api.py
+test/test_batch_api.py
+test/test_batch_v1_api.py
+test/test_certificates_api.py
+test/test_certificates_v1_api.py
+test/test_certificates_v1alpha1_api.py
+test/test_certificates_v1beta1_api.py
+test/test_coordination_api.py
+test/test_coordination_v1_api.py
+test/test_coordination_v1alpha2_api.py
+test/test_coordination_v1beta1_api.py
+test/test_core_api.py
+test/test_core_v1_api.py
+test/test_core_v1_endpoint_port.py
+test/test_core_v1_event.py
+test/test_core_v1_event_list.py
+test/test_core_v1_event_series.py
+test/test_core_v1_resource_claim.py
+test/test_custom_objects_api.py
+test/test_discovery_api.py
+test/test_discovery_v1_api.py
+test/test_discovery_v1_endpoint_port.py
+test/test_events_api.py
+test/test_events_v1_api.py
+test/test_events_v1_event.py
+test/test_events_v1_event_list.py
+test/test_events_v1_event_series.py
+test/test_flowcontrol_apiserver_api.py
+test/test_flowcontrol_apiserver_v1_api.py
+test/test_flowcontrol_v1_subject.py
+test/test_internal_apiserver_api.py
+test/test_internal_apiserver_v1alpha1_api.py
+test/test_logs_api.py
+test/test_networking_api.py
+test/test_networking_v1_api.py
+test/test_networking_v1beta1_api.py
+test/test_node_api.py
+test/test_node_v1_api.py
+test/test_openid_api.py
+test/test_policy_api.py
+test/test_policy_v1_api.py
+test/test_rbac_authorization_api.py
+test/test_rbac_authorization_v1_api.py
+test/test_rbac_v1_subject.py
+test/test_resource_api.py
+test/test_resource_v1_api.py
+test/test_resource_v1_resource_claim.py
+test/test_resource_v1alpha3_api.py
+test/test_resource_v1beta1_api.py
+test/test_resource_v1beta2_api.py
+test/test_scheduling_api.py
+test/test_scheduling_v1_api.py
+test/test_scheduling_v1alpha1_api.py
+test/test_storage_api.py
+test/test_storage_v1_api.py
+test/test_storage_v1_token_request.py
+test/test_storage_v1beta1_api.py
+test/test_storagemigration_api.py
+test/test_storagemigration_v1beta1_api.py
+test/test_v1_affinity.py
+test/test_v1_aggregation_rule.py
+test/test_v1_allocated_device_status.py
+test/test_v1_allocation_result.py
+test/test_v1_api_group.py
+test/test_v1_api_group_list.py
+test/test_v1_api_resource.py
+test/test_v1_api_resource_list.py
+test/test_v1_api_service.py
+test/test_v1_api_service_condition.py
+test/test_v1_api_service_list.py
+test/test_v1_api_service_spec.py
+test/test_v1_api_service_status.py
+test/test_v1_api_versions.py
+test/test_v1_app_armor_profile.py
+test/test_v1_attached_volume.py
+test/test_v1_audit_annotation.py
+test/test_v1_aws_elastic_block_store_volume_source.py
+test/test_v1_azure_disk_volume_source.py
+test/test_v1_azure_file_persistent_volume_source.py
+test/test_v1_azure_file_volume_source.py
+test/test_v1_binding.py
+test/test_v1_bound_object_reference.py
+test/test_v1_capabilities.py
+test/test_v1_capacity_request_policy.py
+test/test_v1_capacity_request_policy_range.py
+test/test_v1_capacity_requirements.py
+test/test_v1_cel_device_selector.py
+test/test_v1_ceph_fs_persistent_volume_source.py
+test/test_v1_ceph_fs_volume_source.py
+test/test_v1_certificate_signing_request.py
+test/test_v1_certificate_signing_request_condition.py
+test/test_v1_certificate_signing_request_list.py
+test/test_v1_certificate_signing_request_spec.py
+test/test_v1_certificate_signing_request_status.py
+test/test_v1_cinder_persistent_volume_source.py
+test/test_v1_cinder_volume_source.py
+test/test_v1_client_ip_config.py
+test/test_v1_cluster_role.py
+test/test_v1_cluster_role_binding.py
+test/test_v1_cluster_role_binding_list.py
+test/test_v1_cluster_role_list.py
+test/test_v1_cluster_trust_bundle_projection.py
+test/test_v1_component_condition.py
+test/test_v1_component_status.py
+test/test_v1_component_status_list.py
+test/test_v1_condition.py
+test/test_v1_config_map.py
+test/test_v1_config_map_env_source.py
+test/test_v1_config_map_key_selector.py
+test/test_v1_config_map_list.py
+test/test_v1_config_map_node_config_source.py
+test/test_v1_config_map_projection.py
+test/test_v1_config_map_volume_source.py
+test/test_v1_container.py
+test/test_v1_container_extended_resource_request.py
+test/test_v1_container_image.py
+test/test_v1_container_port.py
+test/test_v1_container_resize_policy.py
+test/test_v1_container_restart_rule.py
+test/test_v1_container_restart_rule_on_exit_codes.py
+test/test_v1_container_state.py
+test/test_v1_container_state_running.py
+test/test_v1_container_state_terminated.py
+test/test_v1_container_state_waiting.py
+test/test_v1_container_status.py
+test/test_v1_container_user.py
+test/test_v1_controller_revision.py
+test/test_v1_controller_revision_list.py
+test/test_v1_counter.py
+test/test_v1_counter_set.py
+test/test_v1_cron_job.py
+test/test_v1_cron_job_list.py
+test/test_v1_cron_job_spec.py
+test/test_v1_cron_job_status.py
+test/test_v1_cross_version_object_reference.py
+test/test_v1_csi_driver.py
+test/test_v1_csi_driver_list.py
+test/test_v1_csi_driver_spec.py
+test/test_v1_csi_node.py
+test/test_v1_csi_node_driver.py
+test/test_v1_csi_node_list.py
+test/test_v1_csi_node_spec.py
+test/test_v1_csi_persistent_volume_source.py
+test/test_v1_csi_storage_capacity.py
+test/test_v1_csi_storage_capacity_list.py
+test/test_v1_csi_volume_source.py
+test/test_v1_custom_resource_column_definition.py
+test/test_v1_custom_resource_conversion.py
+test/test_v1_custom_resource_definition.py
+test/test_v1_custom_resource_definition_condition.py
+test/test_v1_custom_resource_definition_list.py
+test/test_v1_custom_resource_definition_names.py
+test/test_v1_custom_resource_definition_spec.py
+test/test_v1_custom_resource_definition_status.py
+test/test_v1_custom_resource_definition_version.py
+test/test_v1_custom_resource_subresource_scale.py
+test/test_v1_custom_resource_subresources.py
+test/test_v1_custom_resource_validation.py
+test/test_v1_daemon_endpoint.py
+test/test_v1_daemon_set.py
+test/test_v1_daemon_set_condition.py
+test/test_v1_daemon_set_list.py
+test/test_v1_daemon_set_spec.py
+test/test_v1_daemon_set_status.py
+test/test_v1_daemon_set_update_strategy.py
+test/test_v1_delete_options.py
+test/test_v1_deployment.py
+test/test_v1_deployment_condition.py
+test/test_v1_deployment_list.py
+test/test_v1_deployment_spec.py
+test/test_v1_deployment_status.py
+test/test_v1_deployment_strategy.py
+test/test_v1_device.py
+test/test_v1_device_allocation_configuration.py
+test/test_v1_device_allocation_result.py
+test/test_v1_device_attribute.py
+test/test_v1_device_capacity.py
+test/test_v1_device_claim.py
+test/test_v1_device_claim_configuration.py
+test/test_v1_device_class.py
+test/test_v1_device_class_configuration.py
+test/test_v1_device_class_list.py
+test/test_v1_device_class_spec.py
+test/test_v1_device_constraint.py
+test/test_v1_device_counter_consumption.py
+test/test_v1_device_request.py
+test/test_v1_device_request_allocation_result.py
+test/test_v1_device_selector.py
+test/test_v1_device_sub_request.py
+test/test_v1_device_taint.py
+test/test_v1_device_toleration.py
+test/test_v1_downward_api_projection.py
+test/test_v1_downward_api_volume_file.py
+test/test_v1_downward_api_volume_source.py
+test/test_v1_empty_dir_volume_source.py
+test/test_v1_endpoint.py
+test/test_v1_endpoint_address.py
+test/test_v1_endpoint_conditions.py
+test/test_v1_endpoint_hints.py
+test/test_v1_endpoint_slice.py
+test/test_v1_endpoint_slice_list.py
+test/test_v1_endpoint_subset.py
+test/test_v1_endpoints.py
+test/test_v1_endpoints_list.py
+test/test_v1_env_from_source.py
+test/test_v1_env_var.py
+test/test_v1_env_var_source.py
+test/test_v1_ephemeral_container.py
+test/test_v1_ephemeral_volume_source.py
+test/test_v1_event_source.py
+test/test_v1_eviction.py
+test/test_v1_exact_device_request.py
+test/test_v1_exec_action.py
+test/test_v1_exempt_priority_level_configuration.py
+test/test_v1_expression_warning.py
+test/test_v1_external_documentation.py
+test/test_v1_fc_volume_source.py
+test/test_v1_field_selector_attributes.py
+test/test_v1_field_selector_requirement.py
+test/test_v1_file_key_selector.py
+test/test_v1_flex_persistent_volume_source.py
+test/test_v1_flex_volume_source.py
+test/test_v1_flocker_volume_source.py
+test/test_v1_flow_distinguisher_method.py
+test/test_v1_flow_schema.py
+test/test_v1_flow_schema_condition.py
+test/test_v1_flow_schema_list.py
+test/test_v1_flow_schema_spec.py
+test/test_v1_flow_schema_status.py
+test/test_v1_for_node.py
+test/test_v1_for_zone.py
+test/test_v1_gce_persistent_disk_volume_source.py
+test/test_v1_git_repo_volume_source.py
+test/test_v1_glusterfs_persistent_volume_source.py
+test/test_v1_glusterfs_volume_source.py
+test/test_v1_group_resource.py
+test/test_v1_group_subject.py
+test/test_v1_group_version_for_discovery.py
+test/test_v1_grpc_action.py
+test/test_v1_horizontal_pod_autoscaler.py
+test/test_v1_horizontal_pod_autoscaler_list.py
+test/test_v1_horizontal_pod_autoscaler_spec.py
+test/test_v1_horizontal_pod_autoscaler_status.py
+test/test_v1_host_alias.py
+test/test_v1_host_ip.py
+test/test_v1_host_path_volume_source.py
+test/test_v1_http_get_action.py
+test/test_v1_http_header.py
+test/test_v1_http_ingress_path.py
+test/test_v1_http_ingress_rule_value.py
+test/test_v1_image_volume_source.py
+test/test_v1_ingress.py
+test/test_v1_ingress_backend.py
+test/test_v1_ingress_class.py
+test/test_v1_ingress_class_list.py
+test/test_v1_ingress_class_parameters_reference.py
+test/test_v1_ingress_class_spec.py
+test/test_v1_ingress_list.py
+test/test_v1_ingress_load_balancer_ingress.py
+test/test_v1_ingress_load_balancer_status.py
+test/test_v1_ingress_port_status.py
+test/test_v1_ingress_rule.py
+test/test_v1_ingress_service_backend.py
+test/test_v1_ingress_spec.py
+test/test_v1_ingress_status.py
+test/test_v1_ingress_tls.py
+test/test_v1_ip_address.py
+test/test_v1_ip_address_list.py
+test/test_v1_ip_address_spec.py
+test/test_v1_ip_block.py
+test/test_v1_iscsi_persistent_volume_source.py
+test/test_v1_iscsi_volume_source.py
+test/test_v1_job.py
+test/test_v1_job_condition.py
+test/test_v1_job_list.py
+test/test_v1_job_spec.py
+test/test_v1_job_status.py
+test/test_v1_job_template_spec.py
+test/test_v1_json_schema_props.py
+test/test_v1_key_to_path.py
+test/test_v1_label_selector.py
+test/test_v1_label_selector_attributes.py
+test/test_v1_label_selector_requirement.py
+test/test_v1_lease.py
+test/test_v1_lease_list.py
+test/test_v1_lease_spec.py
+test/test_v1_lifecycle.py
+test/test_v1_lifecycle_handler.py
+test/test_v1_limit_range.py
+test/test_v1_limit_range_item.py
+test/test_v1_limit_range_list.py
+test/test_v1_limit_range_spec.py
+test/test_v1_limit_response.py
+test/test_v1_limited_priority_level_configuration.py
+test/test_v1_linux_container_user.py
+test/test_v1_list_meta.py
+test/test_v1_load_balancer_ingress.py
+test/test_v1_load_balancer_status.py
+test/test_v1_local_object_reference.py
+test/test_v1_local_subject_access_review.py
+test/test_v1_local_volume_source.py
+test/test_v1_managed_fields_entry.py
+test/test_v1_match_condition.py
+test/test_v1_match_resources.py
+test/test_v1_modify_volume_status.py
+test/test_v1_mutating_webhook.py
+test/test_v1_mutating_webhook_configuration.py
+test/test_v1_mutating_webhook_configuration_list.py
+test/test_v1_named_rule_with_operations.py
+test/test_v1_namespace.py
+test/test_v1_namespace_condition.py
+test/test_v1_namespace_list.py
+test/test_v1_namespace_spec.py
+test/test_v1_namespace_status.py
+test/test_v1_network_device_data.py
+test/test_v1_network_policy.py
+test/test_v1_network_policy_egress_rule.py
+test/test_v1_network_policy_ingress_rule.py
+test/test_v1_network_policy_list.py
+test/test_v1_network_policy_peer.py
+test/test_v1_network_policy_port.py
+test/test_v1_network_policy_spec.py
+test/test_v1_nfs_volume_source.py
+test/test_v1_node.py
+test/test_v1_node_address.py
+test/test_v1_node_affinity.py
+test/test_v1_node_condition.py
+test/test_v1_node_config_source.py
+test/test_v1_node_config_status.py
+test/test_v1_node_daemon_endpoints.py
+test/test_v1_node_features.py
+test/test_v1_node_list.py
+test/test_v1_node_runtime_handler.py
+test/test_v1_node_runtime_handler_features.py
+test/test_v1_node_selector.py
+test/test_v1_node_selector_requirement.py
+test/test_v1_node_selector_term.py
+test/test_v1_node_spec.py
+test/test_v1_node_status.py
+test/test_v1_node_swap_status.py
+test/test_v1_node_system_info.py
+test/test_v1_non_resource_attributes.py
+test/test_v1_non_resource_policy_rule.py
+test/test_v1_non_resource_rule.py
+test/test_v1_object_field_selector.py
+test/test_v1_object_meta.py
+test/test_v1_object_reference.py
+test/test_v1_opaque_device_configuration.py
+test/test_v1_overhead.py
+test/test_v1_owner_reference.py
+test/test_v1_param_kind.py
+test/test_v1_param_ref.py
+test/test_v1_parent_reference.py
+test/test_v1_persistent_volume.py
+test/test_v1_persistent_volume_claim.py
+test/test_v1_persistent_volume_claim_condition.py
+test/test_v1_persistent_volume_claim_list.py
+test/test_v1_persistent_volume_claim_spec.py
+test/test_v1_persistent_volume_claim_status.py
+test/test_v1_persistent_volume_claim_template.py
+test/test_v1_persistent_volume_claim_volume_source.py
+test/test_v1_persistent_volume_list.py
+test/test_v1_persistent_volume_spec.py
+test/test_v1_persistent_volume_status.py
+test/test_v1_photon_persistent_disk_volume_source.py
+test/test_v1_pod.py
+test/test_v1_pod_affinity.py
+test/test_v1_pod_affinity_term.py
+test/test_v1_pod_anti_affinity.py
+test/test_v1_pod_certificate_projection.py
+test/test_v1_pod_condition.py
+test/test_v1_pod_disruption_budget.py
+test/test_v1_pod_disruption_budget_list.py
+test/test_v1_pod_disruption_budget_spec.py
+test/test_v1_pod_disruption_budget_status.py
+test/test_v1_pod_dns_config.py
+test/test_v1_pod_dns_config_option.py
+test/test_v1_pod_extended_resource_claim_status.py
+test/test_v1_pod_failure_policy.py
+test/test_v1_pod_failure_policy_on_exit_codes_requirement.py
+test/test_v1_pod_failure_policy_on_pod_conditions_pattern.py
+test/test_v1_pod_failure_policy_rule.py
+test/test_v1_pod_ip.py
+test/test_v1_pod_list.py
+test/test_v1_pod_os.py
+test/test_v1_pod_readiness_gate.py
+test/test_v1_pod_resource_claim.py
+test/test_v1_pod_resource_claim_status.py
+test/test_v1_pod_scheduling_gate.py
+test/test_v1_pod_security_context.py
+test/test_v1_pod_spec.py
+test/test_v1_pod_status.py
+test/test_v1_pod_template.py
+test/test_v1_pod_template_list.py
+test/test_v1_pod_template_spec.py
+test/test_v1_policy_rule.py
+test/test_v1_policy_rules_with_subjects.py
+test/test_v1_port_status.py
+test/test_v1_portworx_volume_source.py
+test/test_v1_preconditions.py
+test/test_v1_preferred_scheduling_term.py
+test/test_v1_priority_class.py
+test/test_v1_priority_class_list.py
+test/test_v1_priority_level_configuration.py
+test/test_v1_priority_level_configuration_condition.py
+test/test_v1_priority_level_configuration_list.py
+test/test_v1_priority_level_configuration_reference.py
+test/test_v1_priority_level_configuration_spec.py
+test/test_v1_priority_level_configuration_status.py
+test/test_v1_probe.py
+test/test_v1_projected_volume_source.py
+test/test_v1_queuing_configuration.py
+test/test_v1_quobyte_volume_source.py
+test/test_v1_rbd_persistent_volume_source.py
+test/test_v1_rbd_volume_source.py
+test/test_v1_replica_set.py
+test/test_v1_replica_set_condition.py
+test/test_v1_replica_set_list.py
+test/test_v1_replica_set_spec.py
+test/test_v1_replica_set_status.py
+test/test_v1_replication_controller.py
+test/test_v1_replication_controller_condition.py
+test/test_v1_replication_controller_list.py
+test/test_v1_replication_controller_spec.py
+test/test_v1_replication_controller_status.py
+test/test_v1_resource_attributes.py
+test/test_v1_resource_claim_consumer_reference.py
+test/test_v1_resource_claim_list.py
+test/test_v1_resource_claim_spec.py
+test/test_v1_resource_claim_status.py
+test/test_v1_resource_claim_template.py
+test/test_v1_resource_claim_template_list.py
+test/test_v1_resource_claim_template_spec.py
+test/test_v1_resource_field_selector.py
+test/test_v1_resource_health.py
+test/test_v1_resource_policy_rule.py
+test/test_v1_resource_pool.py
+test/test_v1_resource_quota.py
+test/test_v1_resource_quota_list.py
+test/test_v1_resource_quota_spec.py
+test/test_v1_resource_quota_status.py
+test/test_v1_resource_requirements.py
+test/test_v1_resource_rule.py
+test/test_v1_resource_slice.py
+test/test_v1_resource_slice_list.py
+test/test_v1_resource_slice_spec.py
+test/test_v1_resource_status.py
+test/test_v1_role.py
+test/test_v1_role_binding.py
+test/test_v1_role_binding_list.py
+test/test_v1_role_list.py
+test/test_v1_role_ref.py
+test/test_v1_rolling_update_daemon_set.py
+test/test_v1_rolling_update_deployment.py
+test/test_v1_rolling_update_stateful_set_strategy.py
+test/test_v1_rule_with_operations.py
+test/test_v1_runtime_class.py
+test/test_v1_runtime_class_list.py
+test/test_v1_scale.py
+test/test_v1_scale_io_persistent_volume_source.py
+test/test_v1_scale_io_volume_source.py
+test/test_v1_scale_spec.py
+test/test_v1_scale_status.py
+test/test_v1_scheduling.py
+test/test_v1_scope_selector.py
+test/test_v1_scoped_resource_selector_requirement.py
+test/test_v1_se_linux_options.py
+test/test_v1_seccomp_profile.py
+test/test_v1_secret.py
+test/test_v1_secret_env_source.py
+test/test_v1_secret_key_selector.py
+test/test_v1_secret_list.py
+test/test_v1_secret_projection.py
+test/test_v1_secret_reference.py
+test/test_v1_secret_volume_source.py
+test/test_v1_security_context.py
+test/test_v1_selectable_field.py
+test/test_v1_self_subject_access_review.py
+test/test_v1_self_subject_access_review_spec.py
+test/test_v1_self_subject_review.py
+test/test_v1_self_subject_review_status.py
+test/test_v1_self_subject_rules_review.py
+test/test_v1_self_subject_rules_review_spec.py
+test/test_v1_server_address_by_client_cidr.py
+test/test_v1_service.py
+test/test_v1_service_account.py
+test/test_v1_service_account_list.py
+test/test_v1_service_account_subject.py
+test/test_v1_service_account_token_projection.py
+test/test_v1_service_backend_port.py
+test/test_v1_service_cidr.py
+test/test_v1_service_cidr_list.py
+test/test_v1_service_cidr_spec.py
+test/test_v1_service_cidr_status.py
+test/test_v1_service_list.py
+test/test_v1_service_port.py
+test/test_v1_service_spec.py
+test/test_v1_service_status.py
+test/test_v1_session_affinity_config.py
+test/test_v1_sleep_action.py
+test/test_v1_stateful_set.py
+test/test_v1_stateful_set_condition.py
+test/test_v1_stateful_set_list.py
+test/test_v1_stateful_set_ordinals.py
+test/test_v1_stateful_set_persistent_volume_claim_retention_policy.py
+test/test_v1_stateful_set_spec.py
+test/test_v1_stateful_set_status.py
+test/test_v1_stateful_set_update_strategy.py
+test/test_v1_status.py
+test/test_v1_status_cause.py
+test/test_v1_status_details.py
+test/test_v1_storage_class.py
+test/test_v1_storage_class_list.py
+test/test_v1_storage_os_persistent_volume_source.py
+test/test_v1_storage_os_volume_source.py
+test/test_v1_subject_access_review.py
+test/test_v1_subject_access_review_spec.py
+test/test_v1_subject_access_review_status.py
+test/test_v1_subject_rules_review_status.py
+test/test_v1_success_policy.py
+test/test_v1_success_policy_rule.py
+test/test_v1_sysctl.py
+test/test_v1_taint.py
+test/test_v1_tcp_socket_action.py
+test/test_v1_token_request_spec.py
+test/test_v1_token_request_status.py
+test/test_v1_token_review.py
+test/test_v1_token_review_spec.py
+test/test_v1_token_review_status.py
+test/test_v1_toleration.py
+test/test_v1_topology_selector_label_requirement.py
+test/test_v1_topology_selector_term.py
+test/test_v1_topology_spread_constraint.py
+test/test_v1_type_checking.py
+test/test_v1_typed_local_object_reference.py
+test/test_v1_typed_object_reference.py
+test/test_v1_uncounted_terminated_pods.py
+test/test_v1_user_info.py
+test/test_v1_user_subject.py
+test/test_v1_validating_admission_policy.py
+test/test_v1_validating_admission_policy_binding.py
+test/test_v1_validating_admission_policy_binding_list.py
+test/test_v1_validating_admission_policy_binding_spec.py
+test/test_v1_validating_admission_policy_list.py
+test/test_v1_validating_admission_policy_spec.py
+test/test_v1_validating_admission_policy_status.py
+test/test_v1_validating_webhook.py
+test/test_v1_validating_webhook_configuration.py
+test/test_v1_validating_webhook_configuration_list.py
+test/test_v1_validation.py
+test/test_v1_validation_rule.py
+test/test_v1_variable.py
+test/test_v1_volume.py
+test/test_v1_volume_attachment.py
+test/test_v1_volume_attachment_list.py
+test/test_v1_volume_attachment_source.py
+test/test_v1_volume_attachment_spec.py
+test/test_v1_volume_attachment_status.py
+test/test_v1_volume_attributes_class.py
+test/test_v1_volume_attributes_class_list.py
+test/test_v1_volume_device.py
+test/test_v1_volume_error.py
+test/test_v1_volume_mount.py
+test/test_v1_volume_mount_status.py
+test/test_v1_volume_node_affinity.py
+test/test_v1_volume_node_resources.py
+test/test_v1_volume_projection.py
+test/test_v1_volume_resource_requirements.py
+test/test_v1_vsphere_virtual_disk_volume_source.py
+test/test_v1_watch_event.py
+test/test_v1_webhook_conversion.py
+test/test_v1_weighted_pod_affinity_term.py
+test/test_v1_windows_security_context_options.py
+test/test_v1_workload_reference.py
+test/test_v1alpha1_apply_configuration.py
+test/test_v1alpha1_cluster_trust_bundle.py
+test/test_v1alpha1_cluster_trust_bundle_list.py
+test/test_v1alpha1_cluster_trust_bundle_spec.py
+test/test_v1alpha1_gang_scheduling_policy.py
+test/test_v1alpha1_json_patch.py
+test/test_v1alpha1_match_condition.py
+test/test_v1alpha1_match_resources.py
+test/test_v1alpha1_mutating_admission_policy.py
+test/test_v1alpha1_mutating_admission_policy_binding.py
+test/test_v1alpha1_mutating_admission_policy_binding_list.py
+test/test_v1alpha1_mutating_admission_policy_binding_spec.py
+test/test_v1alpha1_mutating_admission_policy_list.py
+test/test_v1alpha1_mutating_admission_policy_spec.py
+test/test_v1alpha1_mutation.py
+test/test_v1alpha1_named_rule_with_operations.py
+test/test_v1alpha1_param_kind.py
+test/test_v1alpha1_param_ref.py
+test/test_v1alpha1_pod_group.py
+test/test_v1alpha1_pod_group_policy.py
+test/test_v1alpha1_server_storage_version.py
+test/test_v1alpha1_storage_version.py
+test/test_v1alpha1_storage_version_condition.py
+test/test_v1alpha1_storage_version_list.py
+test/test_v1alpha1_storage_version_status.py
+test/test_v1alpha1_typed_local_object_reference.py
+test/test_v1alpha1_variable.py
+test/test_v1alpha1_workload.py
+test/test_v1alpha1_workload_list.py
+test/test_v1alpha1_workload_spec.py
+test/test_v1alpha2_lease_candidate.py
+test/test_v1alpha2_lease_candidate_list.py
+test/test_v1alpha2_lease_candidate_spec.py
+test/test_v1alpha3_device_taint.py
+test/test_v1alpha3_device_taint_rule.py
+test/test_v1alpha3_device_taint_rule_list.py
+test/test_v1alpha3_device_taint_rule_spec.py
+test/test_v1alpha3_device_taint_rule_status.py
+test/test_v1alpha3_device_taint_selector.py
+test/test_v1beta1_allocated_device_status.py
+test/test_v1beta1_allocation_result.py
+test/test_v1beta1_apply_configuration.py
+test/test_v1beta1_basic_device.py
+test/test_v1beta1_capacity_request_policy.py
+test/test_v1beta1_capacity_request_policy_range.py
+test/test_v1beta1_capacity_requirements.py
+test/test_v1beta1_cel_device_selector.py
+test/test_v1beta1_cluster_trust_bundle.py
+test/test_v1beta1_cluster_trust_bundle_list.py
+test/test_v1beta1_cluster_trust_bundle_spec.py
+test/test_v1beta1_counter.py
+test/test_v1beta1_counter_set.py
+test/test_v1beta1_device.py
+test/test_v1beta1_device_allocation_configuration.py
+test/test_v1beta1_device_allocation_result.py
+test/test_v1beta1_device_attribute.py
+test/test_v1beta1_device_capacity.py
+test/test_v1beta1_device_claim.py
+test/test_v1beta1_device_claim_configuration.py
+test/test_v1beta1_device_class.py
+test/test_v1beta1_device_class_configuration.py
+test/test_v1beta1_device_class_list.py
+test/test_v1beta1_device_class_spec.py
+test/test_v1beta1_device_constraint.py
+test/test_v1beta1_device_counter_consumption.py
+test/test_v1beta1_device_request.py
+test/test_v1beta1_device_request_allocation_result.py
+test/test_v1beta1_device_selector.py
+test/test_v1beta1_device_sub_request.py
+test/test_v1beta1_device_taint.py
+test/test_v1beta1_device_toleration.py
+test/test_v1beta1_ip_address.py
+test/test_v1beta1_ip_address_list.py
+test/test_v1beta1_ip_address_spec.py
+test/test_v1beta1_json_patch.py
+test/test_v1beta1_lease_candidate.py
+test/test_v1beta1_lease_candidate_list.py
+test/test_v1beta1_lease_candidate_spec.py
+test/test_v1beta1_match_condition.py
+test/test_v1beta1_match_resources.py
+test/test_v1beta1_mutating_admission_policy.py
+test/test_v1beta1_mutating_admission_policy_binding.py
+test/test_v1beta1_mutating_admission_policy_binding_list.py
+test/test_v1beta1_mutating_admission_policy_binding_spec.py
+test/test_v1beta1_mutating_admission_policy_list.py
+test/test_v1beta1_mutating_admission_policy_spec.py
+test/test_v1beta1_mutation.py
+test/test_v1beta1_named_rule_with_operations.py
+test/test_v1beta1_network_device_data.py
+test/test_v1beta1_opaque_device_configuration.py
+test/test_v1beta1_param_kind.py
+test/test_v1beta1_param_ref.py
+test/test_v1beta1_parent_reference.py
+test/test_v1beta1_pod_certificate_request.py
+test/test_v1beta1_pod_certificate_request_list.py
+test/test_v1beta1_pod_certificate_request_spec.py
+test/test_v1beta1_pod_certificate_request_status.py
+test/test_v1beta1_resource_claim.py
+test/test_v1beta1_resource_claim_consumer_reference.py
+test/test_v1beta1_resource_claim_list.py
+test/test_v1beta1_resource_claim_spec.py
+test/test_v1beta1_resource_claim_status.py
+test/test_v1beta1_resource_claim_template.py
+test/test_v1beta1_resource_claim_template_list.py
+test/test_v1beta1_resource_claim_template_spec.py
+test/test_v1beta1_resource_pool.py
+test/test_v1beta1_resource_slice.py
+test/test_v1beta1_resource_slice_list.py
+test/test_v1beta1_resource_slice_spec.py
+test/test_v1beta1_service_cidr.py
+test/test_v1beta1_service_cidr_list.py
+test/test_v1beta1_service_cidr_spec.py
+test/test_v1beta1_service_cidr_status.py
+test/test_v1beta1_storage_version_migration.py
+test/test_v1beta1_storage_version_migration_list.py
+test/test_v1beta1_storage_version_migration_spec.py
+test/test_v1beta1_storage_version_migration_status.py
+test/test_v1beta1_variable.py
+test/test_v1beta1_volume_attributes_class.py
+test/test_v1beta1_volume_attributes_class_list.py
+test/test_v1beta2_allocated_device_status.py
+test/test_v1beta2_allocation_result.py
+test/test_v1beta2_capacity_request_policy.py
+test/test_v1beta2_capacity_request_policy_range.py
+test/test_v1beta2_capacity_requirements.py
+test/test_v1beta2_cel_device_selector.py
+test/test_v1beta2_counter.py
+test/test_v1beta2_counter_set.py
+test/test_v1beta2_device.py
+test/test_v1beta2_device_allocation_configuration.py
+test/test_v1beta2_device_allocation_result.py
+test/test_v1beta2_device_attribute.py
+test/test_v1beta2_device_capacity.py
+test/test_v1beta2_device_claim.py
+test/test_v1beta2_device_claim_configuration.py
+test/test_v1beta2_device_class.py
+test/test_v1beta2_device_class_configuration.py
+test/test_v1beta2_device_class_list.py
+test/test_v1beta2_device_class_spec.py
+test/test_v1beta2_device_constraint.py
+test/test_v1beta2_device_counter_consumption.py
+test/test_v1beta2_device_request.py
+test/test_v1beta2_device_request_allocation_result.py
+test/test_v1beta2_device_selector.py
+test/test_v1beta2_device_sub_request.py
+test/test_v1beta2_device_taint.py
+test/test_v1beta2_device_toleration.py
+test/test_v1beta2_exact_device_request.py
+test/test_v1beta2_network_device_data.py
+test/test_v1beta2_opaque_device_configuration.py
+test/test_v1beta2_resource_claim.py
+test/test_v1beta2_resource_claim_consumer_reference.py
+test/test_v1beta2_resource_claim_list.py
+test/test_v1beta2_resource_claim_spec.py
+test/test_v1beta2_resource_claim_status.py
+test/test_v1beta2_resource_claim_template.py
+test/test_v1beta2_resource_claim_template_list.py
+test/test_v1beta2_resource_claim_template_spec.py
+test/test_v1beta2_resource_pool.py
+test/test_v1beta2_resource_slice.py
+test/test_v1beta2_resource_slice_list.py
+test/test_v1beta2_resource_slice_spec.py
+test/test_v2_api_group_discovery.py
+test/test_v2_api_group_discovery_list.py
+test/test_v2_api_resource_discovery.py
+test/test_v2_api_subresource_discovery.py
+test/test_v2_api_version_discovery.py
+test/test_v2_container_resource_metric_source.py
+test/test_v2_container_resource_metric_status.py
+test/test_v2_cross_version_object_reference.py
+test/test_v2_external_metric_source.py
+test/test_v2_external_metric_status.py
+test/test_v2_horizontal_pod_autoscaler.py
+test/test_v2_horizontal_pod_autoscaler_behavior.py
+test/test_v2_horizontal_pod_autoscaler_condition.py
+test/test_v2_horizontal_pod_autoscaler_list.py
+test/test_v2_horizontal_pod_autoscaler_spec.py
+test/test_v2_horizontal_pod_autoscaler_status.py
+test/test_v2_hpa_scaling_policy.py
+test/test_v2_hpa_scaling_rules.py
+test/test_v2_metric_identifier.py
+test/test_v2_metric_spec.py
+test/test_v2_metric_status.py
+test/test_v2_metric_target.py
+test/test_v2_metric_value_status.py
+test/test_v2_object_metric_source.py
+test/test_v2_object_metric_status.py
+test/test_v2_pods_metric_source.py
+test/test_v2_pods_metric_status.py
+test/test_v2_resource_metric_source.py
+test/test_v2_resource_metric_status.py
+test/test_v2beta1_api_group_discovery.py
+test/test_v2beta1_api_group_discovery_list.py
+test/test_v2beta1_api_resource_discovery.py
+test/test_v2beta1_api_subresource_discovery.py
+test/test_v2beta1_api_version_discovery.py
+test/test_version_api.py
+test/test_version_info.py
+test/test_well_known_api.py
diff --git a/kubernetes/.openapi-generator/VERSION b/kubernetes/.openapi-generator/VERSION
index 8191138914..cd802a1ec4 100644
--- a/kubernetes/.openapi-generator/VERSION
+++ b/kubernetes/.openapi-generator/VERSION
@@ -1 +1 @@
-4.3.0
\ No newline at end of file
+6.6.0
\ No newline at end of file
diff --git a/kubernetes/.openapi-generator/swagger.json-default.sha256 b/kubernetes/.openapi-generator/swagger.json-default.sha256
new file mode 100644
index 0000000000..2fd73dc6da
--- /dev/null
+++ b/kubernetes/.openapi-generator/swagger.json-default.sha256
@@ -0,0 +1 @@
+550c55f434bcea9a33b26c3dd2fae687acbf0fc36dc0031bb6858be079ca138b
\ No newline at end of file
diff --git a/kubernetes/README.md b/kubernetes/README.md
index effedf1f25..7f52c05ce8 100644
--- a/kubernetes/README.md
+++ b/kubernetes/README.md
@@ -5,7 +5,7 @@ This Python package is automatically generated by the [OpenAPI Generator](https:
- API version: release-1.35
- Package version: 35.0.0+snapshot
-- Build package: org.openapitools.codegen.languages.PythonClientCodegen
+- Build package: org.openapitools.codegen.languages.PythonLegacyClientCodegen
## Requirements.
@@ -46,22 +46,30 @@ Please follow the [installation procedure](#installation--usage) and then run th
```python
from __future__ import print_function
+
import time
import kubernetes.client
from kubernetes.client.rest import ApiException
from pprint import pprint
-configuration = kubernetes.client.Configuration()
+# Defining the host is optional and defaults to http://localhost
+# See configuration.py for a list of all supported configuration parameters.
+configuration = kubernetes.client.Configuration(
+ host = "http://localhost"
+)
+
+# The kubernetes.client must configure the authentication and authorization parameters
+# in accordance with the API server security policy.
+# Examples for each auth method are provided below, use the example that
+# satisfies your auth use case.
+
# Configure API key authorization: BearerToken
-configuration.api_key['authorization'] = 'YOUR_API_KEY'
+configuration.api_key['BearerToken'] = 'YOUR_API_KEY'
+
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
-# configuration.api_key_prefix['authorization'] = 'Bearer'
+# configuration.api_key_prefix['BearerToken'] = 'Bearer'
-# Defining host is optional and default to http://localhost
-configuration.host = "http://localhost"
-# Defining host is optional and default to http://localhost
-configuration.host = "http://localhost"
# Enter a context with an instance of the API kubernetes.client
with kubernetes.client.ApiClient(configuration) as api_client:
# Create an instance of the API class
@@ -1672,6 +1680,11 @@ Class | Method | HTTP request | Description
- [V1beta2ResourceSlice](docs/V1beta2ResourceSlice.md)
- [V1beta2ResourceSliceList](docs/V1beta2ResourceSliceList.md)
- [V1beta2ResourceSliceSpec](docs/V1beta2ResourceSliceSpec.md)
+ - [V2APIGroupDiscovery](docs/V2APIGroupDiscovery.md)
+ - [V2APIGroupDiscoveryList](docs/V2APIGroupDiscoveryList.md)
+ - [V2APIResourceDiscovery](docs/V2APIResourceDiscovery.md)
+ - [V2APISubresourceDiscovery](docs/V2APISubresourceDiscovery.md)
+ - [V2APIVersionDiscovery](docs/V2APIVersionDiscovery.md)
- [V2ContainerResourceMetricSource](docs/V2ContainerResourceMetricSource.md)
- [V2ContainerResourceMetricStatus](docs/V2ContainerResourceMetricStatus.md)
- [V2CrossVersionObjectReference](docs/V2CrossVersionObjectReference.md)
@@ -1696,13 +1709,21 @@ Class | Method | HTTP request | Description
- [V2PodsMetricStatus](docs/V2PodsMetricStatus.md)
- [V2ResourceMetricSource](docs/V2ResourceMetricSource.md)
- [V2ResourceMetricStatus](docs/V2ResourceMetricStatus.md)
+ - [V2beta1APIGroupDiscovery](docs/V2beta1APIGroupDiscovery.md)
+ - [V2beta1APIGroupDiscoveryList](docs/V2beta1APIGroupDiscoveryList.md)
+ - [V2beta1APIResourceDiscovery](docs/V2beta1APIResourceDiscovery.md)
+ - [V2beta1APISubresourceDiscovery](docs/V2beta1APISubresourceDiscovery.md)
+ - [V2beta1APIVersionDiscovery](docs/V2beta1APIVersionDiscovery.md)
- [VersionInfo](docs/VersionInfo.md)
+
## Documentation For Authorization
-## BearerToken
+Authentication schemes defined for the API:
+
+### BearerToken
- **Type**: API key
- **API key parameter name**: authorization
diff --git a/kubernetes/base/stream/ws_client.py b/kubernetes/base/stream/ws_client.py
index 10c6c1bcd5..a4c0497ad2 100644
--- a/kubernetes/base/stream/ws_client.py
+++ b/kubernetes/base/stream/ws_client.py
@@ -254,8 +254,16 @@ def close(self, **kwargs):
self.sock.close(**kwargs)
-WSResponse = collections.namedtuple('WSResponse', ['data'])
+#WSResponse = collections.namedtuple('WSResponse', ['data', 'status', 'getheader'])
+class WSResponse:
+ def __init__(self, data, status):
+ self.status = status
+ self.data = data
+
+ def getheader(self, name, default=None):
+ """Returns a given response header."""
+ return None
class PortForward:
def __init__(self, websocket, ports):
@@ -536,9 +544,9 @@ def websocket_call(configuration, _method, url, **kwargs):
client.run_forever(timeout=_request_timeout)
all = client.read_all()
if binary:
- return WSResponse(all)
+ return WSResponse(data=all, status=200)
else:
- return WSResponse('%s' % ''.join(all))
+ return WSResponse(data='%s' % ''.join(all), status=200)
except (Exception, KeyboardInterrupt, SystemExit) as e:
raise ApiException(status=0, reason=str(e))
diff --git a/kubernetes/base/watch/watch.py b/kubernetes/base/watch/watch.py
index 40e5e75bf6..44fbe49141 100644
--- a/kubernetes/base/watch/watch.py
+++ b/kubernetes/base/watch/watch.py
@@ -18,7 +18,7 @@
from kubernetes import client
-PYDOC_RETURN_LABEL = ":return:"
+PYDOC_RETURN_LABEL = ":rtype:"
PYDOC_FOLLOW_PARAM = ":param bool follow:"
# Removing this suffix from return type name should give us event's object
diff --git a/kubernetes/base/watch/watch_test.py b/kubernetes/base/watch/watch_test.py
index d872020b45..07869095b6 100644
--- a/kubernetes/base/watch/watch_test.py
+++ b/kubernetes/base/watch/watch_test.py
@@ -45,7 +45,7 @@ def test_watch_with_decode(self):
fake_api = Mock()
fake_api.get_namespaces = Mock(return_value=fake_resp)
- fake_api.get_namespaces.__doc__ = ':return: V1NamespaceList'
+ fake_api.get_namespaces.__doc__ = ':rtype: V1NamespaceList'
w = Watch()
count = 1
@@ -92,7 +92,7 @@ def test_watch_with_interspersed_newlines(self):
fake_api = Mock()
fake_api.get_namespaces = Mock(return_value=fake_resp)
- fake_api.get_namespaces.__doc__ = ':return: V1NamespaceList'
+ fake_api.get_namespaces.__doc__ = ':rtype: V1NamespaceList'
w = Watch()
count = 0
@@ -129,7 +129,7 @@ def test_watch_with_multibyte_utf8(self):
fake_api = Mock()
fake_api.get_configmaps = Mock(return_value=fake_resp)
- fake_api.get_configmaps.__doc__ = ':return: V1ConfigMapList'
+ fake_api.get_configmaps.__doc__ = ':rtype: V1ConfigMapList'
w = Watch()
count = 0
@@ -175,7 +175,7 @@ def test_watch_with_invalid_utf8(self):
fake_api = Mock()
fake_api.get_configmaps = Mock(return_value=fake_resp)
- fake_api.get_configmaps.__doc__ = ':return: V1ConfigMapList'
+ fake_api.get_configmaps.__doc__ = ':rtype: V1ConfigMapList'
w = Watch()
count = 0
@@ -204,7 +204,7 @@ def test_watch_for_follow(self):
fake_api = Mock()
fake_api.read_namespaced_pod_log = Mock(return_value=fake_resp)
- fake_api.read_namespaced_pod_log.__doc__ = ':param bool follow:\n:return: str'
+ fake_api.read_namespaced_pod_log.__doc__ = ':param bool follow:\n:rtype: str'
w = Watch()
count = 1
@@ -256,7 +256,7 @@ def get_values(*args, **kwargs):
fake_api = Mock()
fake_api.get_namespaces = Mock(return_value=fake_resp)
- fake_api.get_namespaces.__doc__ = ':return: V1NamespaceList'
+ fake_api.get_namespaces.__doc__ = ':rtype: V1NamespaceList'
w = Watch()
# ensure we keep our requested resource version or the version latest
@@ -303,7 +303,7 @@ def test_watch_stream_twice(self):
fake_api = Mock()
fake_api.get_namespaces = Mock(return_value=fake_resp)
- fake_api.get_namespaces.__doc__ = ':return: V1NamespaceList'
+ fake_api.get_namespaces.__doc__ = ':rtype: V1NamespaceList'
count = 1
for e in w.stream(fake_api.get_namespaces):
@@ -330,7 +330,7 @@ def test_watch_stream_loop(self):
fake_api = Mock()
fake_api.get_namespaces = Mock(return_value=fake_resp)
- fake_api.get_namespaces.__doc__ = ':return: V1NamespaceList'
+ fake_api.get_namespaces.__doc__ = ':rtype: V1NamespaceList'
count = 0
@@ -597,7 +597,7 @@ def test_pod_log_empty_lines(self):
#
# fake_api = Mock()
# fake_api.get_namespaces = Mock(return_value=fake_resp)
-# fake_api.get_namespaces.__doc__ = ':return: V1NamespaceList'
+# fake_api.get_namespaces.__doc__ = ':rtype: V1NamespaceList'
#
# # test case with deserialize=True
# w = Watch()
diff --git a/kubernetes/client/__init__.py b/kubernetes/client/__init__.py
index 8df717e198..60f55b63cb 100644
--- a/kubernetes/client/__init__.py
+++ b/kubernetes/client/__init__.py
@@ -90,6 +90,7 @@
from kubernetes.client.exceptions import ApiTypeError
from kubernetes.client.exceptions import ApiValueError
from kubernetes.client.exceptions import ApiKeyError
+from kubernetes.client.exceptions import ApiAttributeError
from kubernetes.client.exceptions import ApiException
# import models into sdk package
from kubernetes.client.models.admissionregistration_v1_service_reference import AdmissionregistrationV1ServiceReference
@@ -788,6 +789,11 @@
from kubernetes.client.models.v1beta2_resource_slice import V1beta2ResourceSlice
from kubernetes.client.models.v1beta2_resource_slice_list import V1beta2ResourceSliceList
from kubernetes.client.models.v1beta2_resource_slice_spec import V1beta2ResourceSliceSpec
+from kubernetes.client.models.v2_api_group_discovery import V2APIGroupDiscovery
+from kubernetes.client.models.v2_api_group_discovery_list import V2APIGroupDiscoveryList
+from kubernetes.client.models.v2_api_resource_discovery import V2APIResourceDiscovery
+from kubernetes.client.models.v2_api_subresource_discovery import V2APISubresourceDiscovery
+from kubernetes.client.models.v2_api_version_discovery import V2APIVersionDiscovery
from kubernetes.client.models.v2_container_resource_metric_source import V2ContainerResourceMetricSource
from kubernetes.client.models.v2_container_resource_metric_status import V2ContainerResourceMetricStatus
from kubernetes.client.models.v2_cross_version_object_reference import V2CrossVersionObjectReference
@@ -812,5 +818,10 @@
from kubernetes.client.models.v2_pods_metric_status import V2PodsMetricStatus
from kubernetes.client.models.v2_resource_metric_source import V2ResourceMetricSource
from kubernetes.client.models.v2_resource_metric_status import V2ResourceMetricStatus
+from kubernetes.client.models.v2beta1_api_group_discovery import V2beta1APIGroupDiscovery
+from kubernetes.client.models.v2beta1_api_group_discovery_list import V2beta1APIGroupDiscoveryList
+from kubernetes.client.models.v2beta1_api_resource_discovery import V2beta1APIResourceDiscovery
+from kubernetes.client.models.v2beta1_api_subresource_discovery import V2beta1APISubresourceDiscovery
+from kubernetes.client.models.v2beta1_api_version_discovery import V2beta1APIVersionDiscovery
from kubernetes.client.models.version_info import VersionInfo
diff --git a/kubernetes/client/api/admissionregistration_api.py b/kubernetes/client/api/admissionregistration_api.py
index 27972c729b..61cf3c50d8 100644
--- a/kubernetes/client/api/admissionregistration_api.py
+++ b/kubernetes/client/api/admissionregistration_api.py
@@ -42,20 +42,24 @@ def get_api_group(self, **kwargs): # noqa: E501
get information of a group # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_group(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIGroup
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIGroup
"""
kwargs['_return_http_data_only'] = True
return self.get_api_group_with_http_info(**kwargs) # noqa: E501
@@ -66,22 +70,32 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
get information of a group # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_group_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIGroup, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIGroup, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -93,7 +107,10 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -112,7 +129,7 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -125,6 +142,11 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIGroup",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/', 'GET',
path_params,
@@ -133,10 +155,11 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIGroup', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/admissionregistration_v1_api.py b/kubernetes/client/api/admissionregistration_v1_api.py
index b580fc3480..a3731e3a57 100644
--- a/kubernetes/client/api/admissionregistration_v1_api.py
+++ b/kubernetes/client/api/admissionregistration_v1_api.py
@@ -42,25 +42,34 @@ def create_mutating_webhook_configuration(self, body, **kwargs): # noqa: E501
create a MutatingWebhookConfiguration # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_mutating_webhook_configuration(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1MutatingWebhookConfiguration body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1MutatingWebhookConfiguration
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1MutatingWebhookConfiguration
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1MutatingWebhookConfiguration
"""
kwargs['_return_http_data_only'] = True
return self.create_mutating_webhook_configuration_with_http_info(body, **kwargs) # noqa: E501
@@ -71,27 +80,42 @@ def create_mutating_webhook_configuration_with_http_info(self, body, **kwargs):
create a MutatingWebhookConfiguration # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_mutating_webhook_configuration_with_http_info(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1MutatingWebhookConfiguration body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1MutatingWebhookConfiguration
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1MutatingWebhookConfiguration, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1MutatingWebhookConfiguration, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -108,7 +132,10 @@ def create_mutating_webhook_configuration_with_http_info(self, body, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -121,8 +148,7 @@ def create_mutating_webhook_configuration_with_http_info(self, body, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_mutating_webhook_configuration`") # noqa: E501
collection_formats = {}
@@ -130,16 +156,16 @@ def create_mutating_webhook_configuration_with_http_info(self, body, **kwargs):
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -154,6 +180,13 @@ def create_mutating_webhook_configuration_with_http_info(self, body, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1MutatingWebhookConfiguration",
+ 201: "V1MutatingWebhookConfiguration",
+ 202: "V1MutatingWebhookConfiguration",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/mutatingwebhookconfigurations', 'POST',
path_params,
@@ -162,13 +195,14 @@ def create_mutating_webhook_configuration_with_http_info(self, body, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1MutatingWebhookConfiguration', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_validating_admission_policy(self, body, **kwargs): # noqa: E501
"""create_validating_admission_policy # noqa: E501
@@ -176,25 +210,34 @@ def create_validating_admission_policy(self, body, **kwargs): # noqa: E501
create a ValidatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_validating_admission_policy(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1ValidatingAdmissionPolicy body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1ValidatingAdmissionPolicy
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ValidatingAdmissionPolicy
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ValidatingAdmissionPolicy
"""
kwargs['_return_http_data_only'] = True
return self.create_validating_admission_policy_with_http_info(body, **kwargs) # noqa: E501
@@ -205,27 +248,42 @@ def create_validating_admission_policy_with_http_info(self, body, **kwargs): #
create a ValidatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_validating_admission_policy_with_http_info(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1ValidatingAdmissionPolicy body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1ValidatingAdmissionPolicy
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ValidatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ValidatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -242,7 +300,10 @@ def create_validating_admission_policy_with_http_info(self, body, **kwargs): #
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -255,8 +316,7 @@ def create_validating_admission_policy_with_http_info(self, body, **kwargs): #
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_validating_admission_policy`") # noqa: E501
collection_formats = {}
@@ -264,16 +324,16 @@ def create_validating_admission_policy_with_http_info(self, body, **kwargs): #
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -288,6 +348,13 @@ def create_validating_admission_policy_with_http_info(self, body, **kwargs): #
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ValidatingAdmissionPolicy",
+ 201: "V1ValidatingAdmissionPolicy",
+ 202: "V1ValidatingAdmissionPolicy",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/validatingadmissionpolicies', 'POST',
path_params,
@@ -296,13 +363,14 @@ def create_validating_admission_policy_with_http_info(self, body, **kwargs): #
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ValidatingAdmissionPolicy', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_validating_admission_policy_binding(self, body, **kwargs): # noqa: E501
"""create_validating_admission_policy_binding # noqa: E501
@@ -310,25 +378,34 @@ def create_validating_admission_policy_binding(self, body, **kwargs): # noqa: E
create a ValidatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_validating_admission_policy_binding(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1ValidatingAdmissionPolicyBinding body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1ValidatingAdmissionPolicyBinding
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ValidatingAdmissionPolicyBinding
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ValidatingAdmissionPolicyBinding
"""
kwargs['_return_http_data_only'] = True
return self.create_validating_admission_policy_binding_with_http_info(body, **kwargs) # noqa: E501
@@ -339,27 +416,42 @@ def create_validating_admission_policy_binding_with_http_info(self, body, **kwar
create a ValidatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_validating_admission_policy_binding_with_http_info(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1ValidatingAdmissionPolicyBinding body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1ValidatingAdmissionPolicyBinding
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ValidatingAdmissionPolicyBinding, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ValidatingAdmissionPolicyBinding, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -376,7 +468,10 @@ def create_validating_admission_policy_binding_with_http_info(self, body, **kwar
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -389,8 +484,7 @@ def create_validating_admission_policy_binding_with_http_info(self, body, **kwar
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_validating_admission_policy_binding`") # noqa: E501
collection_formats = {}
@@ -398,16 +492,16 @@ def create_validating_admission_policy_binding_with_http_info(self, body, **kwar
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -422,6 +516,13 @@ def create_validating_admission_policy_binding_with_http_info(self, body, **kwar
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ValidatingAdmissionPolicyBinding",
+ 201: "V1ValidatingAdmissionPolicyBinding",
+ 202: "V1ValidatingAdmissionPolicyBinding",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/validatingadmissionpolicybindings', 'POST',
path_params,
@@ -430,13 +531,14 @@ def create_validating_admission_policy_binding_with_http_info(self, body, **kwar
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ValidatingAdmissionPolicyBinding', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_validating_webhook_configuration(self, body, **kwargs): # noqa: E501
"""create_validating_webhook_configuration # noqa: E501
@@ -444,25 +546,34 @@ def create_validating_webhook_configuration(self, body, **kwargs): # noqa: E501
create a ValidatingWebhookConfiguration # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_validating_webhook_configuration(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1ValidatingWebhookConfiguration body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1ValidatingWebhookConfiguration
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ValidatingWebhookConfiguration
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ValidatingWebhookConfiguration
"""
kwargs['_return_http_data_only'] = True
return self.create_validating_webhook_configuration_with_http_info(body, **kwargs) # noqa: E501
@@ -473,27 +584,42 @@ def create_validating_webhook_configuration_with_http_info(self, body, **kwargs)
create a ValidatingWebhookConfiguration # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_validating_webhook_configuration_with_http_info(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1ValidatingWebhookConfiguration body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1ValidatingWebhookConfiguration
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ValidatingWebhookConfiguration, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ValidatingWebhookConfiguration, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -510,7 +636,10 @@ def create_validating_webhook_configuration_with_http_info(self, body, **kwargs)
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -523,8 +652,7 @@ def create_validating_webhook_configuration_with_http_info(self, body, **kwargs)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_validating_webhook_configuration`") # noqa: E501
collection_formats = {}
@@ -532,16 +660,16 @@ def create_validating_webhook_configuration_with_http_info(self, body, **kwargs)
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -556,6 +684,13 @@ def create_validating_webhook_configuration_with_http_info(self, body, **kwargs)
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ValidatingWebhookConfiguration",
+ 201: "V1ValidatingWebhookConfiguration",
+ 202: "V1ValidatingWebhookConfiguration",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/validatingwebhookconfigurations', 'POST',
path_params,
@@ -564,13 +699,14 @@ def create_validating_webhook_configuration_with_http_info(self, body, **kwargs)
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ValidatingWebhookConfiguration', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_mutating_webhook_configuration(self, **kwargs): # noqa: E501
"""delete_collection_mutating_webhook_configuration # noqa: E501
@@ -578,35 +714,54 @@ def delete_collection_mutating_webhook_configuration(self, **kwargs): # noqa: E
delete collection of MutatingWebhookConfiguration # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_mutating_webhook_configuration(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_mutating_webhook_configuration_with_http_info(**kwargs) # noqa: E501
@@ -617,37 +772,62 @@ def delete_collection_mutating_webhook_configuration_with_http_info(self, **kwar
delete collection of MutatingWebhookConfiguration # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_mutating_webhook_configuration_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -674,7 +854,10 @@ def delete_collection_mutating_webhook_configuration_with_http_info(self, **kwar
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -692,36 +875,36 @@ def delete_collection_mutating_webhook_configuration_with_http_info(self, **kwar
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -736,6 +919,11 @@ def delete_collection_mutating_webhook_configuration_with_http_info(self, **kwar
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/mutatingwebhookconfigurations', 'DELETE',
path_params,
@@ -744,13 +932,14 @@ def delete_collection_mutating_webhook_configuration_with_http_info(self, **kwar
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_validating_admission_policy(self, **kwargs): # noqa: E501
"""delete_collection_validating_admission_policy # noqa: E501
@@ -758,35 +947,54 @@ def delete_collection_validating_admission_policy(self, **kwargs): # noqa: E501
delete collection of ValidatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_validating_admission_policy(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_validating_admission_policy_with_http_info(**kwargs) # noqa: E501
@@ -797,37 +1005,62 @@ def delete_collection_validating_admission_policy_with_http_info(self, **kwargs)
delete collection of ValidatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_validating_admission_policy_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -854,7 +1087,10 @@ def delete_collection_validating_admission_policy_with_http_info(self, **kwargs)
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -872,36 +1108,36 @@ def delete_collection_validating_admission_policy_with_http_info(self, **kwargs)
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -916,6 +1152,11 @@ def delete_collection_validating_admission_policy_with_http_info(self, **kwargs)
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/validatingadmissionpolicies', 'DELETE',
path_params,
@@ -924,13 +1165,14 @@ def delete_collection_validating_admission_policy_with_http_info(self, **kwargs)
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_validating_admission_policy_binding(self, **kwargs): # noqa: E501
"""delete_collection_validating_admission_policy_binding # noqa: E501
@@ -938,35 +1180,54 @@ def delete_collection_validating_admission_policy_binding(self, **kwargs): # no
delete collection of ValidatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_validating_admission_policy_binding(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_validating_admission_policy_binding_with_http_info(**kwargs) # noqa: E501
@@ -977,37 +1238,62 @@ def delete_collection_validating_admission_policy_binding_with_http_info(self, *
delete collection of ValidatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_validating_admission_policy_binding_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1034,7 +1320,10 @@ def delete_collection_validating_admission_policy_binding_with_http_info(self, *
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1052,36 +1341,36 @@ def delete_collection_validating_admission_policy_binding_with_http_info(self, *
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1096,6 +1385,11 @@ def delete_collection_validating_admission_policy_binding_with_http_info(self, *
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/validatingadmissionpolicybindings', 'DELETE',
path_params,
@@ -1104,13 +1398,14 @@ def delete_collection_validating_admission_policy_binding_with_http_info(self, *
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_validating_webhook_configuration(self, **kwargs): # noqa: E501
"""delete_collection_validating_webhook_configuration # noqa: E501
@@ -1118,35 +1413,54 @@ def delete_collection_validating_webhook_configuration(self, **kwargs): # noqa:
delete collection of ValidatingWebhookConfiguration # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_validating_webhook_configuration(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_validating_webhook_configuration_with_http_info(**kwargs) # noqa: E501
@@ -1157,37 +1471,62 @@ def delete_collection_validating_webhook_configuration_with_http_info(self, **kw
delete collection of ValidatingWebhookConfiguration # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_validating_webhook_configuration_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1214,7 +1553,10 @@ def delete_collection_validating_webhook_configuration_with_http_info(self, **kw
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1232,36 +1574,36 @@ def delete_collection_validating_webhook_configuration_with_http_info(self, **kw
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1276,6 +1618,11 @@ def delete_collection_validating_webhook_configuration_with_http_info(self, **kw
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/validatingwebhookconfigurations', 'DELETE',
path_params,
@@ -1284,13 +1631,14 @@ def delete_collection_validating_webhook_configuration_with_http_info(self, **kw
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_mutating_webhook_configuration(self, name, **kwargs): # noqa: E501
"""delete_mutating_webhook_configuration # noqa: E501
@@ -1298,28 +1646,40 @@ def delete_mutating_webhook_configuration(self, name, **kwargs): # noqa: E501
delete a MutatingWebhookConfiguration # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_mutating_webhook_configuration(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingWebhookConfiguration (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the MutatingWebhookConfiguration (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_mutating_webhook_configuration_with_http_info(name, **kwargs) # noqa: E501
@@ -1330,30 +1690,48 @@ def delete_mutating_webhook_configuration_with_http_info(self, name, **kwargs):
delete a MutatingWebhookConfiguration # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_mutating_webhook_configuration_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingWebhookConfiguration (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the MutatingWebhookConfiguration (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1373,7 +1751,10 @@ def delete_mutating_webhook_configuration_with_http_info(self, name, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1386,8 +1767,7 @@ def delete_mutating_webhook_configuration_with_http_info(self, name, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_mutating_webhook_configuration`") # noqa: E501
collection_formats = {}
@@ -1397,20 +1777,20 @@ def delete_mutating_webhook_configuration_with_http_info(self, name, **kwargs):
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1425,6 +1805,12 @@ def delete_mutating_webhook_configuration_with_http_info(self, name, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/mutatingwebhookconfigurations/{name}', 'DELETE',
path_params,
@@ -1433,13 +1819,14 @@ def delete_mutating_webhook_configuration_with_http_info(self, name, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_validating_admission_policy(self, name, **kwargs): # noqa: E501
"""delete_validating_admission_policy # noqa: E501
@@ -1447,28 +1834,40 @@ def delete_validating_admission_policy(self, name, **kwargs): # noqa: E501
delete a ValidatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_validating_admission_policy(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingAdmissionPolicy (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the ValidatingAdmissionPolicy (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_validating_admission_policy_with_http_info(name, **kwargs) # noqa: E501
@@ -1479,30 +1878,48 @@ def delete_validating_admission_policy_with_http_info(self, name, **kwargs): #
delete a ValidatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_validating_admission_policy_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingAdmissionPolicy (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the ValidatingAdmissionPolicy (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1522,7 +1939,10 @@ def delete_validating_admission_policy_with_http_info(self, name, **kwargs): #
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1535,8 +1955,7 @@ def delete_validating_admission_policy_with_http_info(self, name, **kwargs): #
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_validating_admission_policy`") # noqa: E501
collection_formats = {}
@@ -1546,20 +1965,20 @@ def delete_validating_admission_policy_with_http_info(self, name, **kwargs): #
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1574,6 +1993,12 @@ def delete_validating_admission_policy_with_http_info(self, name, **kwargs): #
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/validatingadmissionpolicies/{name}', 'DELETE',
path_params,
@@ -1582,13 +2007,14 @@ def delete_validating_admission_policy_with_http_info(self, name, **kwargs): #
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_validating_admission_policy_binding(self, name, **kwargs): # noqa: E501
"""delete_validating_admission_policy_binding # noqa: E501
@@ -1596,28 +2022,40 @@ def delete_validating_admission_policy_binding(self, name, **kwargs): # noqa: E
delete a ValidatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_validating_admission_policy_binding(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingAdmissionPolicyBinding (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the ValidatingAdmissionPolicyBinding (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_validating_admission_policy_binding_with_http_info(name, **kwargs) # noqa: E501
@@ -1628,30 +2066,48 @@ def delete_validating_admission_policy_binding_with_http_info(self, name, **kwar
delete a ValidatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_validating_admission_policy_binding_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingAdmissionPolicyBinding (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the ValidatingAdmissionPolicyBinding (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1671,7 +2127,10 @@ def delete_validating_admission_policy_binding_with_http_info(self, name, **kwar
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1684,8 +2143,7 @@ def delete_validating_admission_policy_binding_with_http_info(self, name, **kwar
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_validating_admission_policy_binding`") # noqa: E501
collection_formats = {}
@@ -1695,20 +2153,20 @@ def delete_validating_admission_policy_binding_with_http_info(self, name, **kwar
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1723,6 +2181,12 @@ def delete_validating_admission_policy_binding_with_http_info(self, name, **kwar
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/validatingadmissionpolicybindings/{name}', 'DELETE',
path_params,
@@ -1731,13 +2195,14 @@ def delete_validating_admission_policy_binding_with_http_info(self, name, **kwar
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_validating_webhook_configuration(self, name, **kwargs): # noqa: E501
"""delete_validating_webhook_configuration # noqa: E501
@@ -1745,28 +2210,40 @@ def delete_validating_webhook_configuration(self, name, **kwargs): # noqa: E501
delete a ValidatingWebhookConfiguration # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_validating_webhook_configuration(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingWebhookConfiguration (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the ValidatingWebhookConfiguration (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_validating_webhook_configuration_with_http_info(name, **kwargs) # noqa: E501
@@ -1777,30 +2254,48 @@ def delete_validating_webhook_configuration_with_http_info(self, name, **kwargs)
delete a ValidatingWebhookConfiguration # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_validating_webhook_configuration_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingWebhookConfiguration (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the ValidatingWebhookConfiguration (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1820,7 +2315,10 @@ def delete_validating_webhook_configuration_with_http_info(self, name, **kwargs)
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1833,8 +2331,7 @@ def delete_validating_webhook_configuration_with_http_info(self, name, **kwargs)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_validating_webhook_configuration`") # noqa: E501
collection_formats = {}
@@ -1844,20 +2341,20 @@ def delete_validating_webhook_configuration_with_http_info(self, name, **kwargs)
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1872,6 +2369,12 @@ def delete_validating_webhook_configuration_with_http_info(self, name, **kwargs)
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/validatingwebhookconfigurations/{name}', 'DELETE',
path_params,
@@ -1880,13 +2383,14 @@ def delete_validating_webhook_configuration_with_http_info(self, name, **kwargs)
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def get_api_resources(self, **kwargs): # noqa: E501
"""get_api_resources # noqa: E501
@@ -1894,20 +2398,24 @@ def get_api_resources(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIResourceList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIResourceList
"""
kwargs['_return_http_data_only'] = True
return self.get_api_resources_with_http_info(**kwargs) # noqa: E501
@@ -1918,22 +2426,32 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1945,7 +2463,10 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1964,7 +2485,7 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1977,6 +2498,11 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIResourceList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/', 'GET',
path_params,
@@ -1985,13 +2511,14 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIResourceList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_mutating_webhook_configuration(self, **kwargs): # noqa: E501
"""list_mutating_webhook_configuration # noqa: E501
@@ -1999,31 +2526,46 @@ def list_mutating_webhook_configuration(self, **kwargs): # noqa: E501
list or watch objects of kind MutatingWebhookConfiguration # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_mutating_webhook_configuration(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1MutatingWebhookConfigurationList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1MutatingWebhookConfigurationList
"""
kwargs['_return_http_data_only'] = True
return self.list_mutating_webhook_configuration_with_http_info(**kwargs) # noqa: E501
@@ -2034,33 +2576,54 @@ def list_mutating_webhook_configuration_with_http_info(self, **kwargs): # noqa:
list or watch objects of kind MutatingWebhookConfiguration # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_mutating_webhook_configuration_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1MutatingWebhookConfigurationList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1MutatingWebhookConfigurationList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2083,7 +2646,10 @@ def list_mutating_webhook_configuration_with_http_info(self, **kwargs): # noqa:
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2101,30 +2667,30 @@ def list_mutating_webhook_configuration_with_http_info(self, **kwargs): # noqa:
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2137,6 +2703,11 @@ def list_mutating_webhook_configuration_with_http_info(self, **kwargs): # noqa:
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1MutatingWebhookConfigurationList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/mutatingwebhookconfigurations', 'GET',
path_params,
@@ -2145,13 +2716,14 @@ def list_mutating_webhook_configuration_with_http_info(self, **kwargs): # noqa:
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1MutatingWebhookConfigurationList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_validating_admission_policy(self, **kwargs): # noqa: E501
"""list_validating_admission_policy # noqa: E501
@@ -2159,31 +2731,46 @@ def list_validating_admission_policy(self, **kwargs): # noqa: E501
list or watch objects of kind ValidatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_validating_admission_policy(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ValidatingAdmissionPolicyList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ValidatingAdmissionPolicyList
"""
kwargs['_return_http_data_only'] = True
return self.list_validating_admission_policy_with_http_info(**kwargs) # noqa: E501
@@ -2194,33 +2781,54 @@ def list_validating_admission_policy_with_http_info(self, **kwargs): # noqa: E5
list or watch objects of kind ValidatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_validating_admission_policy_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ValidatingAdmissionPolicyList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ValidatingAdmissionPolicyList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2243,7 +2851,10 @@ def list_validating_admission_policy_with_http_info(self, **kwargs): # noqa: E5
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2261,30 +2872,30 @@ def list_validating_admission_policy_with_http_info(self, **kwargs): # noqa: E5
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2297,6 +2908,11 @@ def list_validating_admission_policy_with_http_info(self, **kwargs): # noqa: E5
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ValidatingAdmissionPolicyList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/validatingadmissionpolicies', 'GET',
path_params,
@@ -2305,13 +2921,14 @@ def list_validating_admission_policy_with_http_info(self, **kwargs): # noqa: E5
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ValidatingAdmissionPolicyList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_validating_admission_policy_binding(self, **kwargs): # noqa: E501
"""list_validating_admission_policy_binding # noqa: E501
@@ -2319,31 +2936,46 @@ def list_validating_admission_policy_binding(self, **kwargs): # noqa: E501
list or watch objects of kind ValidatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_validating_admission_policy_binding(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ValidatingAdmissionPolicyBindingList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ValidatingAdmissionPolicyBindingList
"""
kwargs['_return_http_data_only'] = True
return self.list_validating_admission_policy_binding_with_http_info(**kwargs) # noqa: E501
@@ -2354,33 +2986,54 @@ def list_validating_admission_policy_binding_with_http_info(self, **kwargs): #
list or watch objects of kind ValidatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_validating_admission_policy_binding_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ValidatingAdmissionPolicyBindingList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ValidatingAdmissionPolicyBindingList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2403,7 +3056,10 @@ def list_validating_admission_policy_binding_with_http_info(self, **kwargs): #
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2421,30 +3077,30 @@ def list_validating_admission_policy_binding_with_http_info(self, **kwargs): #
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2457,6 +3113,11 @@ def list_validating_admission_policy_binding_with_http_info(self, **kwargs): #
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ValidatingAdmissionPolicyBindingList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/validatingadmissionpolicybindings', 'GET',
path_params,
@@ -2465,13 +3126,14 @@ def list_validating_admission_policy_binding_with_http_info(self, **kwargs): #
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ValidatingAdmissionPolicyBindingList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_validating_webhook_configuration(self, **kwargs): # noqa: E501
"""list_validating_webhook_configuration # noqa: E501
@@ -2479,31 +3141,46 @@ def list_validating_webhook_configuration(self, **kwargs): # noqa: E501
list or watch objects of kind ValidatingWebhookConfiguration # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_validating_webhook_configuration(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ValidatingWebhookConfigurationList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ValidatingWebhookConfigurationList
"""
kwargs['_return_http_data_only'] = True
return self.list_validating_webhook_configuration_with_http_info(**kwargs) # noqa: E501
@@ -2514,33 +3191,54 @@ def list_validating_webhook_configuration_with_http_info(self, **kwargs): # noq
list or watch objects of kind ValidatingWebhookConfiguration # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_validating_webhook_configuration_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ValidatingWebhookConfigurationList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ValidatingWebhookConfigurationList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2563,7 +3261,10 @@ def list_validating_webhook_configuration_with_http_info(self, **kwargs): # noq
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2581,30 +3282,30 @@ def list_validating_webhook_configuration_with_http_info(self, **kwargs): # noq
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2617,6 +3318,11 @@ def list_validating_webhook_configuration_with_http_info(self, **kwargs): # noq
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ValidatingWebhookConfigurationList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/validatingwebhookconfigurations', 'GET',
path_params,
@@ -2625,13 +3331,14 @@ def list_validating_webhook_configuration_with_http_info(self, **kwargs): # noq
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ValidatingWebhookConfigurationList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_mutating_webhook_configuration(self, name, body, **kwargs): # noqa: E501
"""patch_mutating_webhook_configuration # noqa: E501
@@ -2639,27 +3346,38 @@ def patch_mutating_webhook_configuration(self, name, body, **kwargs): # noqa: E
partially update the specified MutatingWebhookConfiguration # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_mutating_webhook_configuration(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingWebhookConfiguration (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the MutatingWebhookConfiguration (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1MutatingWebhookConfiguration
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1MutatingWebhookConfiguration
"""
kwargs['_return_http_data_only'] = True
return self.patch_mutating_webhook_configuration_with_http_info(name, body, **kwargs) # noqa: E501
@@ -2670,29 +3388,46 @@ def patch_mutating_webhook_configuration_with_http_info(self, name, body, **kwar
partially update the specified MutatingWebhookConfiguration # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_mutating_webhook_configuration_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingWebhookConfiguration (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the MutatingWebhookConfiguration (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1MutatingWebhookConfiguration, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1MutatingWebhookConfiguration, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2711,7 +3446,10 @@ def patch_mutating_webhook_configuration_with_http_info(self, name, body, **kwar
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2724,12 +3462,10 @@ def patch_mutating_webhook_configuration_with_http_info(self, name, body, **kwar
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_mutating_webhook_configuration`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_mutating_webhook_configuration`") # noqa: E501
collection_formats = {}
@@ -2739,18 +3475,18 @@ def patch_mutating_webhook_configuration_with_http_info(self, name, body, **kwar
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2763,12 +3499,22 @@ def patch_mutating_webhook_configuration_with_http_info(self, name, body, **kwar
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1MutatingWebhookConfiguration",
+ 201: "V1MutatingWebhookConfiguration",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/mutatingwebhookconfigurations/{name}', 'PATCH',
path_params,
@@ -2777,13 +3523,14 @@ def patch_mutating_webhook_configuration_with_http_info(self, name, body, **kwar
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1MutatingWebhookConfiguration', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_validating_admission_policy(self, name, body, **kwargs): # noqa: E501
"""patch_validating_admission_policy # noqa: E501
@@ -2791,27 +3538,38 @@ def patch_validating_admission_policy(self, name, body, **kwargs): # noqa: E501
partially update the specified ValidatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_validating_admission_policy(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingAdmissionPolicy (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ValidatingAdmissionPolicy (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ValidatingAdmissionPolicy
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ValidatingAdmissionPolicy
"""
kwargs['_return_http_data_only'] = True
return self.patch_validating_admission_policy_with_http_info(name, body, **kwargs) # noqa: E501
@@ -2822,29 +3580,46 @@ def patch_validating_admission_policy_with_http_info(self, name, body, **kwargs)
partially update the specified ValidatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_validating_admission_policy_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingAdmissionPolicy (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ValidatingAdmissionPolicy (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ValidatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ValidatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2863,7 +3638,10 @@ def patch_validating_admission_policy_with_http_info(self, name, body, **kwargs)
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2876,12 +3654,10 @@ def patch_validating_admission_policy_with_http_info(self, name, body, **kwargs)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_validating_admission_policy`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_validating_admission_policy`") # noqa: E501
collection_formats = {}
@@ -2891,18 +3667,18 @@ def patch_validating_admission_policy_with_http_info(self, name, body, **kwargs)
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2915,12 +3691,22 @@ def patch_validating_admission_policy_with_http_info(self, name, body, **kwargs)
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ValidatingAdmissionPolicy",
+ 201: "V1ValidatingAdmissionPolicy",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/validatingadmissionpolicies/{name}', 'PATCH',
path_params,
@@ -2929,13 +3715,14 @@ def patch_validating_admission_policy_with_http_info(self, name, body, **kwargs)
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ValidatingAdmissionPolicy', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_validating_admission_policy_binding(self, name, body, **kwargs): # noqa: E501
"""patch_validating_admission_policy_binding # noqa: E501
@@ -2943,27 +3730,38 @@ def patch_validating_admission_policy_binding(self, name, body, **kwargs): # no
partially update the specified ValidatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_validating_admission_policy_binding(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingAdmissionPolicyBinding (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ValidatingAdmissionPolicyBinding (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ValidatingAdmissionPolicyBinding
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ValidatingAdmissionPolicyBinding
"""
kwargs['_return_http_data_only'] = True
return self.patch_validating_admission_policy_binding_with_http_info(name, body, **kwargs) # noqa: E501
@@ -2974,29 +3772,46 @@ def patch_validating_admission_policy_binding_with_http_info(self, name, body, *
partially update the specified ValidatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_validating_admission_policy_binding_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingAdmissionPolicyBinding (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ValidatingAdmissionPolicyBinding (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ValidatingAdmissionPolicyBinding, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ValidatingAdmissionPolicyBinding, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3015,7 +3830,10 @@ def patch_validating_admission_policy_binding_with_http_info(self, name, body, *
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3028,12 +3846,10 @@ def patch_validating_admission_policy_binding_with_http_info(self, name, body, *
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_validating_admission_policy_binding`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_validating_admission_policy_binding`") # noqa: E501
collection_formats = {}
@@ -3043,18 +3859,18 @@ def patch_validating_admission_policy_binding_with_http_info(self, name, body, *
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3067,12 +3883,22 @@ def patch_validating_admission_policy_binding_with_http_info(self, name, body, *
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ValidatingAdmissionPolicyBinding",
+ 201: "V1ValidatingAdmissionPolicyBinding",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/validatingadmissionpolicybindings/{name}', 'PATCH',
path_params,
@@ -3081,13 +3907,14 @@ def patch_validating_admission_policy_binding_with_http_info(self, name, body, *
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ValidatingAdmissionPolicyBinding', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_validating_admission_policy_status(self, name, body, **kwargs): # noqa: E501
"""patch_validating_admission_policy_status # noqa: E501
@@ -3095,27 +3922,38 @@ def patch_validating_admission_policy_status(self, name, body, **kwargs): # noq
partially update status of the specified ValidatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_validating_admission_policy_status(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingAdmissionPolicy (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ValidatingAdmissionPolicy (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ValidatingAdmissionPolicy
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ValidatingAdmissionPolicy
"""
kwargs['_return_http_data_only'] = True
return self.patch_validating_admission_policy_status_with_http_info(name, body, **kwargs) # noqa: E501
@@ -3126,29 +3964,46 @@ def patch_validating_admission_policy_status_with_http_info(self, name, body, **
partially update status of the specified ValidatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_validating_admission_policy_status_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingAdmissionPolicy (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ValidatingAdmissionPolicy (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ValidatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ValidatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3167,7 +4022,10 @@ def patch_validating_admission_policy_status_with_http_info(self, name, body, **
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3180,12 +4038,10 @@ def patch_validating_admission_policy_status_with_http_info(self, name, body, **
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_validating_admission_policy_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_validating_admission_policy_status`") # noqa: E501
collection_formats = {}
@@ -3195,18 +4051,18 @@ def patch_validating_admission_policy_status_with_http_info(self, name, body, **
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3219,12 +4075,22 @@ def patch_validating_admission_policy_status_with_http_info(self, name, body, **
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ValidatingAdmissionPolicy",
+ 201: "V1ValidatingAdmissionPolicy",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/validatingadmissionpolicies/{name}/status', 'PATCH',
path_params,
@@ -3233,13 +4099,14 @@ def patch_validating_admission_policy_status_with_http_info(self, name, body, **
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ValidatingAdmissionPolicy', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_validating_webhook_configuration(self, name, body, **kwargs): # noqa: E501
"""patch_validating_webhook_configuration # noqa: E501
@@ -3247,27 +4114,38 @@ def patch_validating_webhook_configuration(self, name, body, **kwargs): # noqa:
partially update the specified ValidatingWebhookConfiguration # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_validating_webhook_configuration(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingWebhookConfiguration (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ValidatingWebhookConfiguration (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ValidatingWebhookConfiguration
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ValidatingWebhookConfiguration
"""
kwargs['_return_http_data_only'] = True
return self.patch_validating_webhook_configuration_with_http_info(name, body, **kwargs) # noqa: E501
@@ -3278,29 +4156,46 @@ def patch_validating_webhook_configuration_with_http_info(self, name, body, **kw
partially update the specified ValidatingWebhookConfiguration # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_validating_webhook_configuration_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingWebhookConfiguration (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ValidatingWebhookConfiguration (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ValidatingWebhookConfiguration, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ValidatingWebhookConfiguration, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3319,7 +4214,10 @@ def patch_validating_webhook_configuration_with_http_info(self, name, body, **kw
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3332,12 +4230,10 @@ def patch_validating_webhook_configuration_with_http_info(self, name, body, **kw
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_validating_webhook_configuration`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_validating_webhook_configuration`") # noqa: E501
collection_formats = {}
@@ -3347,18 +4243,18 @@ def patch_validating_webhook_configuration_with_http_info(self, name, body, **kw
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3371,12 +4267,22 @@ def patch_validating_webhook_configuration_with_http_info(self, name, body, **kw
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ValidatingWebhookConfiguration",
+ 201: "V1ValidatingWebhookConfiguration",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/validatingwebhookconfigurations/{name}', 'PATCH',
path_params,
@@ -3385,13 +4291,14 @@ def patch_validating_webhook_configuration_with_http_info(self, name, body, **kw
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ValidatingWebhookConfiguration', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_mutating_webhook_configuration(self, name, **kwargs): # noqa: E501
"""read_mutating_webhook_configuration # noqa: E501
@@ -3399,22 +4306,28 @@ def read_mutating_webhook_configuration(self, name, **kwargs): # noqa: E501
read the specified MutatingWebhookConfiguration # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_mutating_webhook_configuration(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingWebhookConfiguration (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the MutatingWebhookConfiguration (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1MutatingWebhookConfiguration
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1MutatingWebhookConfiguration
"""
kwargs['_return_http_data_only'] = True
return self.read_mutating_webhook_configuration_with_http_info(name, **kwargs) # noqa: E501
@@ -3425,24 +4338,36 @@ def read_mutating_webhook_configuration_with_http_info(self, name, **kwargs): #
read the specified MutatingWebhookConfiguration # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_mutating_webhook_configuration_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingWebhookConfiguration (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the MutatingWebhookConfiguration (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1MutatingWebhookConfiguration, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1MutatingWebhookConfiguration, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3456,7 +4381,10 @@ def read_mutating_webhook_configuration_with_http_info(self, name, **kwargs): #
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3469,8 +4397,7 @@ def read_mutating_webhook_configuration_with_http_info(self, name, **kwargs): #
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_mutating_webhook_configuration`") # noqa: E501
collection_formats = {}
@@ -3480,10 +4407,10 @@ def read_mutating_webhook_configuration_with_http_info(self, name, **kwargs): #
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3496,6 +4423,11 @@ def read_mutating_webhook_configuration_with_http_info(self, name, **kwargs): #
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1MutatingWebhookConfiguration",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/mutatingwebhookconfigurations/{name}', 'GET',
path_params,
@@ -3504,13 +4436,14 @@ def read_mutating_webhook_configuration_with_http_info(self, name, **kwargs): #
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1MutatingWebhookConfiguration', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_validating_admission_policy(self, name, **kwargs): # noqa: E501
"""read_validating_admission_policy # noqa: E501
@@ -3518,22 +4451,28 @@ def read_validating_admission_policy(self, name, **kwargs): # noqa: E501
read the specified ValidatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_validating_admission_policy(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingAdmissionPolicy (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ValidatingAdmissionPolicy (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ValidatingAdmissionPolicy
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ValidatingAdmissionPolicy
"""
kwargs['_return_http_data_only'] = True
return self.read_validating_admission_policy_with_http_info(name, **kwargs) # noqa: E501
@@ -3544,24 +4483,36 @@ def read_validating_admission_policy_with_http_info(self, name, **kwargs): # no
read the specified ValidatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_validating_admission_policy_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingAdmissionPolicy (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ValidatingAdmissionPolicy (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ValidatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ValidatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3575,7 +4526,10 @@ def read_validating_admission_policy_with_http_info(self, name, **kwargs): # no
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3588,8 +4542,7 @@ def read_validating_admission_policy_with_http_info(self, name, **kwargs): # no
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_validating_admission_policy`") # noqa: E501
collection_formats = {}
@@ -3599,10 +4552,10 @@ def read_validating_admission_policy_with_http_info(self, name, **kwargs): # no
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3615,6 +4568,11 @@ def read_validating_admission_policy_with_http_info(self, name, **kwargs): # no
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ValidatingAdmissionPolicy",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/validatingadmissionpolicies/{name}', 'GET',
path_params,
@@ -3623,13 +4581,14 @@ def read_validating_admission_policy_with_http_info(self, name, **kwargs): # no
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ValidatingAdmissionPolicy', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_validating_admission_policy_binding(self, name, **kwargs): # noqa: E501
"""read_validating_admission_policy_binding # noqa: E501
@@ -3637,22 +4596,28 @@ def read_validating_admission_policy_binding(self, name, **kwargs): # noqa: E50
read the specified ValidatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_validating_admission_policy_binding(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingAdmissionPolicyBinding (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ValidatingAdmissionPolicyBinding (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ValidatingAdmissionPolicyBinding
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ValidatingAdmissionPolicyBinding
"""
kwargs['_return_http_data_only'] = True
return self.read_validating_admission_policy_binding_with_http_info(name, **kwargs) # noqa: E501
@@ -3663,24 +4628,36 @@ def read_validating_admission_policy_binding_with_http_info(self, name, **kwargs
read the specified ValidatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_validating_admission_policy_binding_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingAdmissionPolicyBinding (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ValidatingAdmissionPolicyBinding (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ValidatingAdmissionPolicyBinding, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ValidatingAdmissionPolicyBinding, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3694,7 +4671,10 @@ def read_validating_admission_policy_binding_with_http_info(self, name, **kwargs
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3707,8 +4687,7 @@ def read_validating_admission_policy_binding_with_http_info(self, name, **kwargs
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_validating_admission_policy_binding`") # noqa: E501
collection_formats = {}
@@ -3718,10 +4697,10 @@ def read_validating_admission_policy_binding_with_http_info(self, name, **kwargs
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3734,6 +4713,11 @@ def read_validating_admission_policy_binding_with_http_info(self, name, **kwargs
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ValidatingAdmissionPolicyBinding",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/validatingadmissionpolicybindings/{name}', 'GET',
path_params,
@@ -3742,13 +4726,14 @@ def read_validating_admission_policy_binding_with_http_info(self, name, **kwargs
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ValidatingAdmissionPolicyBinding', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_validating_admission_policy_status(self, name, **kwargs): # noqa: E501
"""read_validating_admission_policy_status # noqa: E501
@@ -3756,22 +4741,28 @@ def read_validating_admission_policy_status(self, name, **kwargs): # noqa: E501
read status of the specified ValidatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_validating_admission_policy_status(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingAdmissionPolicy (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ValidatingAdmissionPolicy (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ValidatingAdmissionPolicy
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ValidatingAdmissionPolicy
"""
kwargs['_return_http_data_only'] = True
return self.read_validating_admission_policy_status_with_http_info(name, **kwargs) # noqa: E501
@@ -3782,24 +4773,36 @@ def read_validating_admission_policy_status_with_http_info(self, name, **kwargs)
read status of the specified ValidatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_validating_admission_policy_status_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingAdmissionPolicy (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ValidatingAdmissionPolicy (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ValidatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ValidatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3813,7 +4816,10 @@ def read_validating_admission_policy_status_with_http_info(self, name, **kwargs)
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3826,8 +4832,7 @@ def read_validating_admission_policy_status_with_http_info(self, name, **kwargs)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_validating_admission_policy_status`") # noqa: E501
collection_formats = {}
@@ -3837,10 +4842,10 @@ def read_validating_admission_policy_status_with_http_info(self, name, **kwargs)
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3853,6 +4858,11 @@ def read_validating_admission_policy_status_with_http_info(self, name, **kwargs)
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ValidatingAdmissionPolicy",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/validatingadmissionpolicies/{name}/status', 'GET',
path_params,
@@ -3861,13 +4871,14 @@ def read_validating_admission_policy_status_with_http_info(self, name, **kwargs)
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ValidatingAdmissionPolicy', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_validating_webhook_configuration(self, name, **kwargs): # noqa: E501
"""read_validating_webhook_configuration # noqa: E501
@@ -3875,22 +4886,28 @@ def read_validating_webhook_configuration(self, name, **kwargs): # noqa: E501
read the specified ValidatingWebhookConfiguration # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_validating_webhook_configuration(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingWebhookConfiguration (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ValidatingWebhookConfiguration (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ValidatingWebhookConfiguration
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ValidatingWebhookConfiguration
"""
kwargs['_return_http_data_only'] = True
return self.read_validating_webhook_configuration_with_http_info(name, **kwargs) # noqa: E501
@@ -3901,24 +4918,36 @@ def read_validating_webhook_configuration_with_http_info(self, name, **kwargs):
read the specified ValidatingWebhookConfiguration # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_validating_webhook_configuration_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingWebhookConfiguration (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ValidatingWebhookConfiguration (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ValidatingWebhookConfiguration, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ValidatingWebhookConfiguration, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3932,7 +4961,10 @@ def read_validating_webhook_configuration_with_http_info(self, name, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3945,8 +4977,7 @@ def read_validating_webhook_configuration_with_http_info(self, name, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_validating_webhook_configuration`") # noqa: E501
collection_formats = {}
@@ -3956,10 +4987,10 @@ def read_validating_webhook_configuration_with_http_info(self, name, **kwargs):
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3972,6 +5003,11 @@ def read_validating_webhook_configuration_with_http_info(self, name, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ValidatingWebhookConfiguration",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/validatingwebhookconfigurations/{name}', 'GET',
path_params,
@@ -3980,13 +5016,14 @@ def read_validating_webhook_configuration_with_http_info(self, name, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ValidatingWebhookConfiguration', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_mutating_webhook_configuration(self, name, body, **kwargs): # noqa: E501
"""replace_mutating_webhook_configuration # noqa: E501
@@ -3994,26 +5031,36 @@ def replace_mutating_webhook_configuration(self, name, body, **kwargs): # noqa:
replace the specified MutatingWebhookConfiguration # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_mutating_webhook_configuration(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingWebhookConfiguration (required)
- :param V1MutatingWebhookConfiguration body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the MutatingWebhookConfiguration (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1MutatingWebhookConfiguration
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1MutatingWebhookConfiguration
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1MutatingWebhookConfiguration
"""
kwargs['_return_http_data_only'] = True
return self.replace_mutating_webhook_configuration_with_http_info(name, body, **kwargs) # noqa: E501
@@ -4024,28 +5071,44 @@ def replace_mutating_webhook_configuration_with_http_info(self, name, body, **kw
replace the specified MutatingWebhookConfiguration # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_mutating_webhook_configuration_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingWebhookConfiguration (required)
- :param V1MutatingWebhookConfiguration body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the MutatingWebhookConfiguration (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1MutatingWebhookConfiguration
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1MutatingWebhookConfiguration, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1MutatingWebhookConfiguration, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -4063,7 +5126,10 @@ def replace_mutating_webhook_configuration_with_http_info(self, name, body, **kw
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -4076,12 +5142,10 @@ def replace_mutating_webhook_configuration_with_http_info(self, name, body, **kw
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_mutating_webhook_configuration`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_mutating_webhook_configuration`") # noqa: E501
collection_formats = {}
@@ -4091,16 +5155,16 @@ def replace_mutating_webhook_configuration_with_http_info(self, name, body, **kw
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -4115,6 +5179,12 @@ def replace_mutating_webhook_configuration_with_http_info(self, name, body, **kw
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1MutatingWebhookConfiguration",
+ 201: "V1MutatingWebhookConfiguration",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/mutatingwebhookconfigurations/{name}', 'PUT',
path_params,
@@ -4123,13 +5193,14 @@ def replace_mutating_webhook_configuration_with_http_info(self, name, body, **kw
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1MutatingWebhookConfiguration', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_validating_admission_policy(self, name, body, **kwargs): # noqa: E501
"""replace_validating_admission_policy # noqa: E501
@@ -4137,26 +5208,36 @@ def replace_validating_admission_policy(self, name, body, **kwargs): # noqa: E5
replace the specified ValidatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_validating_admission_policy(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingAdmissionPolicy (required)
- :param V1ValidatingAdmissionPolicy body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ValidatingAdmissionPolicy (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1ValidatingAdmissionPolicy
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ValidatingAdmissionPolicy
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ValidatingAdmissionPolicy
"""
kwargs['_return_http_data_only'] = True
return self.replace_validating_admission_policy_with_http_info(name, body, **kwargs) # noqa: E501
@@ -4167,28 +5248,44 @@ def replace_validating_admission_policy_with_http_info(self, name, body, **kwarg
replace the specified ValidatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_validating_admission_policy_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingAdmissionPolicy (required)
- :param V1ValidatingAdmissionPolicy body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ValidatingAdmissionPolicy (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1ValidatingAdmissionPolicy
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ValidatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ValidatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -4206,7 +5303,10 @@ def replace_validating_admission_policy_with_http_info(self, name, body, **kwarg
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -4219,12 +5319,10 @@ def replace_validating_admission_policy_with_http_info(self, name, body, **kwarg
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_validating_admission_policy`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_validating_admission_policy`") # noqa: E501
collection_formats = {}
@@ -4234,16 +5332,16 @@ def replace_validating_admission_policy_with_http_info(self, name, body, **kwarg
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -4258,6 +5356,12 @@ def replace_validating_admission_policy_with_http_info(self, name, body, **kwarg
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ValidatingAdmissionPolicy",
+ 201: "V1ValidatingAdmissionPolicy",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/validatingadmissionpolicies/{name}', 'PUT',
path_params,
@@ -4266,13 +5370,14 @@ def replace_validating_admission_policy_with_http_info(self, name, body, **kwarg
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ValidatingAdmissionPolicy', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_validating_admission_policy_binding(self, name, body, **kwargs): # noqa: E501
"""replace_validating_admission_policy_binding # noqa: E501
@@ -4280,26 +5385,36 @@ def replace_validating_admission_policy_binding(self, name, body, **kwargs): #
replace the specified ValidatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_validating_admission_policy_binding(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingAdmissionPolicyBinding (required)
- :param V1ValidatingAdmissionPolicyBinding body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ValidatingAdmissionPolicyBinding (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1ValidatingAdmissionPolicyBinding
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ValidatingAdmissionPolicyBinding
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ValidatingAdmissionPolicyBinding
"""
kwargs['_return_http_data_only'] = True
return self.replace_validating_admission_policy_binding_with_http_info(name, body, **kwargs) # noqa: E501
@@ -4310,28 +5425,44 @@ def replace_validating_admission_policy_binding_with_http_info(self, name, body,
replace the specified ValidatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_validating_admission_policy_binding_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingAdmissionPolicyBinding (required)
- :param V1ValidatingAdmissionPolicyBinding body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ValidatingAdmissionPolicyBinding (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1ValidatingAdmissionPolicyBinding
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ValidatingAdmissionPolicyBinding, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ValidatingAdmissionPolicyBinding, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -4349,7 +5480,10 @@ def replace_validating_admission_policy_binding_with_http_info(self, name, body,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -4362,12 +5496,10 @@ def replace_validating_admission_policy_binding_with_http_info(self, name, body,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_validating_admission_policy_binding`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_validating_admission_policy_binding`") # noqa: E501
collection_formats = {}
@@ -4377,16 +5509,16 @@ def replace_validating_admission_policy_binding_with_http_info(self, name, body,
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -4401,6 +5533,12 @@ def replace_validating_admission_policy_binding_with_http_info(self, name, body,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ValidatingAdmissionPolicyBinding",
+ 201: "V1ValidatingAdmissionPolicyBinding",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/validatingadmissionpolicybindings/{name}', 'PUT',
path_params,
@@ -4409,13 +5547,14 @@ def replace_validating_admission_policy_binding_with_http_info(self, name, body,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ValidatingAdmissionPolicyBinding', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_validating_admission_policy_status(self, name, body, **kwargs): # noqa: E501
"""replace_validating_admission_policy_status # noqa: E501
@@ -4423,26 +5562,36 @@ def replace_validating_admission_policy_status(self, name, body, **kwargs): # n
replace status of the specified ValidatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_validating_admission_policy_status(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingAdmissionPolicy (required)
- :param V1ValidatingAdmissionPolicy body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ValidatingAdmissionPolicy (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1ValidatingAdmissionPolicy
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ValidatingAdmissionPolicy
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ValidatingAdmissionPolicy
"""
kwargs['_return_http_data_only'] = True
return self.replace_validating_admission_policy_status_with_http_info(name, body, **kwargs) # noqa: E501
@@ -4453,28 +5602,44 @@ def replace_validating_admission_policy_status_with_http_info(self, name, body,
replace status of the specified ValidatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_validating_admission_policy_status_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingAdmissionPolicy (required)
- :param V1ValidatingAdmissionPolicy body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ValidatingAdmissionPolicy (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1ValidatingAdmissionPolicy
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ValidatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ValidatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -4492,7 +5657,10 @@ def replace_validating_admission_policy_status_with_http_info(self, name, body,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -4505,12 +5673,10 @@ def replace_validating_admission_policy_status_with_http_info(self, name, body,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_validating_admission_policy_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_validating_admission_policy_status`") # noqa: E501
collection_formats = {}
@@ -4520,16 +5686,16 @@ def replace_validating_admission_policy_status_with_http_info(self, name, body,
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -4544,6 +5710,12 @@ def replace_validating_admission_policy_status_with_http_info(self, name, body,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ValidatingAdmissionPolicy",
+ 201: "V1ValidatingAdmissionPolicy",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/validatingadmissionpolicies/{name}/status', 'PUT',
path_params,
@@ -4552,13 +5724,14 @@ def replace_validating_admission_policy_status_with_http_info(self, name, body,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ValidatingAdmissionPolicy', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_validating_webhook_configuration(self, name, body, **kwargs): # noqa: E501
"""replace_validating_webhook_configuration # noqa: E501
@@ -4566,26 +5739,36 @@ def replace_validating_webhook_configuration(self, name, body, **kwargs): # noq
replace the specified ValidatingWebhookConfiguration # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_validating_webhook_configuration(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingWebhookConfiguration (required)
- :param V1ValidatingWebhookConfiguration body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ValidatingWebhookConfiguration (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1ValidatingWebhookConfiguration
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ValidatingWebhookConfiguration
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ValidatingWebhookConfiguration
"""
kwargs['_return_http_data_only'] = True
return self.replace_validating_webhook_configuration_with_http_info(name, body, **kwargs) # noqa: E501
@@ -4596,28 +5779,44 @@ def replace_validating_webhook_configuration_with_http_info(self, name, body, **
replace the specified ValidatingWebhookConfiguration # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_validating_webhook_configuration_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ValidatingWebhookConfiguration (required)
- :param V1ValidatingWebhookConfiguration body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ValidatingWebhookConfiguration (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1ValidatingWebhookConfiguration
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ValidatingWebhookConfiguration, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ValidatingWebhookConfiguration, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -4635,7 +5834,10 @@ def replace_validating_webhook_configuration_with_http_info(self, name, body, **
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -4648,12 +5850,10 @@ def replace_validating_webhook_configuration_with_http_info(self, name, body, **
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_validating_webhook_configuration`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_validating_webhook_configuration`") # noqa: E501
collection_formats = {}
@@ -4663,16 +5863,16 @@ def replace_validating_webhook_configuration_with_http_info(self, name, body, **
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -4687,6 +5887,12 @@ def replace_validating_webhook_configuration_with_http_info(self, name, body, **
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ValidatingWebhookConfiguration",
+ 201: "V1ValidatingWebhookConfiguration",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1/validatingwebhookconfigurations/{name}', 'PUT',
path_params,
@@ -4695,10 +5901,11 @@ def replace_validating_webhook_configuration_with_http_info(self, name, body, **
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ValidatingWebhookConfiguration', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/admissionregistration_v1alpha1_api.py b/kubernetes/client/api/admissionregistration_v1alpha1_api.py
index d0a41aa82e..2f99792536 100644
--- a/kubernetes/client/api/admissionregistration_v1alpha1_api.py
+++ b/kubernetes/client/api/admissionregistration_v1alpha1_api.py
@@ -42,25 +42,34 @@ def create_mutating_admission_policy(self, body, **kwargs): # noqa: E501
create a MutatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_mutating_admission_policy(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1alpha1MutatingAdmissionPolicy body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1alpha1MutatingAdmissionPolicy
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1alpha1MutatingAdmissionPolicy
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1alpha1MutatingAdmissionPolicy
"""
kwargs['_return_http_data_only'] = True
return self.create_mutating_admission_policy_with_http_info(body, **kwargs) # noqa: E501
@@ -71,27 +80,42 @@ def create_mutating_admission_policy_with_http_info(self, body, **kwargs): # no
create a MutatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_mutating_admission_policy_with_http_info(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1alpha1MutatingAdmissionPolicy body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1alpha1MutatingAdmissionPolicy
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1alpha1MutatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1alpha1MutatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -108,7 +132,10 @@ def create_mutating_admission_policy_with_http_info(self, body, **kwargs): # no
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -121,8 +148,7 @@ def create_mutating_admission_policy_with_http_info(self, body, **kwargs): # no
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_mutating_admission_policy`") # noqa: E501
collection_formats = {}
@@ -130,16 +156,16 @@ def create_mutating_admission_policy_with_http_info(self, body, **kwargs): # no
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -154,6 +180,13 @@ def create_mutating_admission_policy_with_http_info(self, body, **kwargs): # no
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1alpha1MutatingAdmissionPolicy",
+ 201: "V1alpha1MutatingAdmissionPolicy",
+ 202: "V1alpha1MutatingAdmissionPolicy",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1alpha1/mutatingadmissionpolicies', 'POST',
path_params,
@@ -162,13 +195,14 @@ def create_mutating_admission_policy_with_http_info(self, body, **kwargs): # no
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1alpha1MutatingAdmissionPolicy', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_mutating_admission_policy_binding(self, body, **kwargs): # noqa: E501
"""create_mutating_admission_policy_binding # noqa: E501
@@ -176,25 +210,34 @@ def create_mutating_admission_policy_binding(self, body, **kwargs): # noqa: E50
create a MutatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_mutating_admission_policy_binding(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1alpha1MutatingAdmissionPolicyBinding body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1alpha1MutatingAdmissionPolicyBinding
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1alpha1MutatingAdmissionPolicyBinding
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1alpha1MutatingAdmissionPolicyBinding
"""
kwargs['_return_http_data_only'] = True
return self.create_mutating_admission_policy_binding_with_http_info(body, **kwargs) # noqa: E501
@@ -205,27 +248,42 @@ def create_mutating_admission_policy_binding_with_http_info(self, body, **kwargs
create a MutatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_mutating_admission_policy_binding_with_http_info(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1alpha1MutatingAdmissionPolicyBinding body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1alpha1MutatingAdmissionPolicyBinding
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1alpha1MutatingAdmissionPolicyBinding, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1alpha1MutatingAdmissionPolicyBinding, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -242,7 +300,10 @@ def create_mutating_admission_policy_binding_with_http_info(self, body, **kwargs
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -255,8 +316,7 @@ def create_mutating_admission_policy_binding_with_http_info(self, body, **kwargs
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_mutating_admission_policy_binding`") # noqa: E501
collection_formats = {}
@@ -264,16 +324,16 @@ def create_mutating_admission_policy_binding_with_http_info(self, body, **kwargs
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -288,6 +348,13 @@ def create_mutating_admission_policy_binding_with_http_info(self, body, **kwargs
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1alpha1MutatingAdmissionPolicyBinding",
+ 201: "V1alpha1MutatingAdmissionPolicyBinding",
+ 202: "V1alpha1MutatingAdmissionPolicyBinding",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1alpha1/mutatingadmissionpolicybindings', 'POST',
path_params,
@@ -296,13 +363,14 @@ def create_mutating_admission_policy_binding_with_http_info(self, body, **kwargs
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1alpha1MutatingAdmissionPolicyBinding', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_mutating_admission_policy(self, **kwargs): # noqa: E501
"""delete_collection_mutating_admission_policy # noqa: E501
@@ -310,35 +378,54 @@ def delete_collection_mutating_admission_policy(self, **kwargs): # noqa: E501
delete collection of MutatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_mutating_admission_policy(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_mutating_admission_policy_with_http_info(**kwargs) # noqa: E501
@@ -349,37 +436,62 @@ def delete_collection_mutating_admission_policy_with_http_info(self, **kwargs):
delete collection of MutatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_mutating_admission_policy_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -406,7 +518,10 @@ def delete_collection_mutating_admission_policy_with_http_info(self, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -424,36 +539,36 @@ def delete_collection_mutating_admission_policy_with_http_info(self, **kwargs):
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -468,6 +583,11 @@ def delete_collection_mutating_admission_policy_with_http_info(self, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1alpha1/mutatingadmissionpolicies', 'DELETE',
path_params,
@@ -476,13 +596,14 @@ def delete_collection_mutating_admission_policy_with_http_info(self, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_mutating_admission_policy_binding(self, **kwargs): # noqa: E501
"""delete_collection_mutating_admission_policy_binding # noqa: E501
@@ -490,35 +611,54 @@ def delete_collection_mutating_admission_policy_binding(self, **kwargs): # noqa
delete collection of MutatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_mutating_admission_policy_binding(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_mutating_admission_policy_binding_with_http_info(**kwargs) # noqa: E501
@@ -529,37 +669,62 @@ def delete_collection_mutating_admission_policy_binding_with_http_info(self, **k
delete collection of MutatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_mutating_admission_policy_binding_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -586,7 +751,10 @@ def delete_collection_mutating_admission_policy_binding_with_http_info(self, **k
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -604,36 +772,36 @@ def delete_collection_mutating_admission_policy_binding_with_http_info(self, **k
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -648,6 +816,11 @@ def delete_collection_mutating_admission_policy_binding_with_http_info(self, **k
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1alpha1/mutatingadmissionpolicybindings', 'DELETE',
path_params,
@@ -656,13 +829,14 @@ def delete_collection_mutating_admission_policy_binding_with_http_info(self, **k
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_mutating_admission_policy(self, name, **kwargs): # noqa: E501
"""delete_mutating_admission_policy # noqa: E501
@@ -670,28 +844,40 @@ def delete_mutating_admission_policy(self, name, **kwargs): # noqa: E501
delete a MutatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_mutating_admission_policy(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicy (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the MutatingAdmissionPolicy (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_mutating_admission_policy_with_http_info(name, **kwargs) # noqa: E501
@@ -702,30 +888,48 @@ def delete_mutating_admission_policy_with_http_info(self, name, **kwargs): # no
delete a MutatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_mutating_admission_policy_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicy (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the MutatingAdmissionPolicy (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -745,7 +949,10 @@ def delete_mutating_admission_policy_with_http_info(self, name, **kwargs): # no
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -758,8 +965,7 @@ def delete_mutating_admission_policy_with_http_info(self, name, **kwargs): # no
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_mutating_admission_policy`") # noqa: E501
collection_formats = {}
@@ -769,20 +975,20 @@ def delete_mutating_admission_policy_with_http_info(self, name, **kwargs): # no
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -797,6 +1003,12 @@ def delete_mutating_admission_policy_with_http_info(self, name, **kwargs): # no
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1alpha1/mutatingadmissionpolicies/{name}', 'DELETE',
path_params,
@@ -805,13 +1017,14 @@ def delete_mutating_admission_policy_with_http_info(self, name, **kwargs): # no
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_mutating_admission_policy_binding(self, name, **kwargs): # noqa: E501
"""delete_mutating_admission_policy_binding # noqa: E501
@@ -819,28 +1032,40 @@ def delete_mutating_admission_policy_binding(self, name, **kwargs): # noqa: E50
delete a MutatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_mutating_admission_policy_binding(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicyBinding (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the MutatingAdmissionPolicyBinding (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_mutating_admission_policy_binding_with_http_info(name, **kwargs) # noqa: E501
@@ -851,30 +1076,48 @@ def delete_mutating_admission_policy_binding_with_http_info(self, name, **kwargs
delete a MutatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_mutating_admission_policy_binding_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicyBinding (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the MutatingAdmissionPolicyBinding (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -894,7 +1137,10 @@ def delete_mutating_admission_policy_binding_with_http_info(self, name, **kwargs
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -907,8 +1153,7 @@ def delete_mutating_admission_policy_binding_with_http_info(self, name, **kwargs
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_mutating_admission_policy_binding`") # noqa: E501
collection_formats = {}
@@ -918,20 +1163,20 @@ def delete_mutating_admission_policy_binding_with_http_info(self, name, **kwargs
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -946,6 +1191,12 @@ def delete_mutating_admission_policy_binding_with_http_info(self, name, **kwargs
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1alpha1/mutatingadmissionpolicybindings/{name}', 'DELETE',
path_params,
@@ -954,13 +1205,14 @@ def delete_mutating_admission_policy_binding_with_http_info(self, name, **kwargs
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def get_api_resources(self, **kwargs): # noqa: E501
"""get_api_resources # noqa: E501
@@ -968,20 +1220,24 @@ def get_api_resources(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIResourceList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIResourceList
"""
kwargs['_return_http_data_only'] = True
return self.get_api_resources_with_http_info(**kwargs) # noqa: E501
@@ -992,22 +1248,32 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1019,7 +1285,10 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1038,7 +1307,7 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1051,6 +1320,11 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIResourceList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1alpha1/', 'GET',
path_params,
@@ -1059,13 +1333,14 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIResourceList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_mutating_admission_policy(self, **kwargs): # noqa: E501
"""list_mutating_admission_policy # noqa: E501
@@ -1073,31 +1348,46 @@ def list_mutating_admission_policy(self, **kwargs): # noqa: E501
list or watch objects of kind MutatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_mutating_admission_policy(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1alpha1MutatingAdmissionPolicyList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1alpha1MutatingAdmissionPolicyList
"""
kwargs['_return_http_data_only'] = True
return self.list_mutating_admission_policy_with_http_info(**kwargs) # noqa: E501
@@ -1108,33 +1398,54 @@ def list_mutating_admission_policy_with_http_info(self, **kwargs): # noqa: E501
list or watch objects of kind MutatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_mutating_admission_policy_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1alpha1MutatingAdmissionPolicyList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1alpha1MutatingAdmissionPolicyList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1157,7 +1468,10 @@ def list_mutating_admission_policy_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1175,30 +1489,30 @@ def list_mutating_admission_policy_with_http_info(self, **kwargs): # noqa: E501
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1211,6 +1525,11 @@ def list_mutating_admission_policy_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1alpha1MutatingAdmissionPolicyList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1alpha1/mutatingadmissionpolicies', 'GET',
path_params,
@@ -1219,13 +1538,14 @@ def list_mutating_admission_policy_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1alpha1MutatingAdmissionPolicyList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_mutating_admission_policy_binding(self, **kwargs): # noqa: E501
"""list_mutating_admission_policy_binding # noqa: E501
@@ -1233,31 +1553,46 @@ def list_mutating_admission_policy_binding(self, **kwargs): # noqa: E501
list or watch objects of kind MutatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_mutating_admission_policy_binding(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1alpha1MutatingAdmissionPolicyBindingList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1alpha1MutatingAdmissionPolicyBindingList
"""
kwargs['_return_http_data_only'] = True
return self.list_mutating_admission_policy_binding_with_http_info(**kwargs) # noqa: E501
@@ -1268,33 +1603,54 @@ def list_mutating_admission_policy_binding_with_http_info(self, **kwargs): # no
list or watch objects of kind MutatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_mutating_admission_policy_binding_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1alpha1MutatingAdmissionPolicyBindingList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1alpha1MutatingAdmissionPolicyBindingList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1317,7 +1673,10 @@ def list_mutating_admission_policy_binding_with_http_info(self, **kwargs): # no
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1335,30 +1694,30 @@ def list_mutating_admission_policy_binding_with_http_info(self, **kwargs): # no
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1371,6 +1730,11 @@ def list_mutating_admission_policy_binding_with_http_info(self, **kwargs): # no
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1alpha1MutatingAdmissionPolicyBindingList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1alpha1/mutatingadmissionpolicybindings', 'GET',
path_params,
@@ -1379,13 +1743,14 @@ def list_mutating_admission_policy_binding_with_http_info(self, **kwargs): # no
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1alpha1MutatingAdmissionPolicyBindingList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_mutating_admission_policy(self, name, body, **kwargs): # noqa: E501
"""patch_mutating_admission_policy # noqa: E501
@@ -1393,27 +1758,38 @@ def patch_mutating_admission_policy(self, name, body, **kwargs): # noqa: E501
partially update the specified MutatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_mutating_admission_policy(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicy (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the MutatingAdmissionPolicy (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1alpha1MutatingAdmissionPolicy
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1alpha1MutatingAdmissionPolicy
"""
kwargs['_return_http_data_only'] = True
return self.patch_mutating_admission_policy_with_http_info(name, body, **kwargs) # noqa: E501
@@ -1424,29 +1800,46 @@ def patch_mutating_admission_policy_with_http_info(self, name, body, **kwargs):
partially update the specified MutatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_mutating_admission_policy_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicy (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the MutatingAdmissionPolicy (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1alpha1MutatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1alpha1MutatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1465,7 +1858,10 @@ def patch_mutating_admission_policy_with_http_info(self, name, body, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1478,12 +1874,10 @@ def patch_mutating_admission_policy_with_http_info(self, name, body, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_mutating_admission_policy`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_mutating_admission_policy`") # noqa: E501
collection_formats = {}
@@ -1493,18 +1887,18 @@ def patch_mutating_admission_policy_with_http_info(self, name, body, **kwargs):
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1517,12 +1911,22 @@ def patch_mutating_admission_policy_with_http_info(self, name, body, **kwargs):
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1alpha1MutatingAdmissionPolicy",
+ 201: "V1alpha1MutatingAdmissionPolicy",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1alpha1/mutatingadmissionpolicies/{name}', 'PATCH',
path_params,
@@ -1531,13 +1935,14 @@ def patch_mutating_admission_policy_with_http_info(self, name, body, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1alpha1MutatingAdmissionPolicy', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_mutating_admission_policy_binding(self, name, body, **kwargs): # noqa: E501
"""patch_mutating_admission_policy_binding # noqa: E501
@@ -1545,27 +1950,38 @@ def patch_mutating_admission_policy_binding(self, name, body, **kwargs): # noqa
partially update the specified MutatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_mutating_admission_policy_binding(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicyBinding (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the MutatingAdmissionPolicyBinding (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1alpha1MutatingAdmissionPolicyBinding
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1alpha1MutatingAdmissionPolicyBinding
"""
kwargs['_return_http_data_only'] = True
return self.patch_mutating_admission_policy_binding_with_http_info(name, body, **kwargs) # noqa: E501
@@ -1576,29 +1992,46 @@ def patch_mutating_admission_policy_binding_with_http_info(self, name, body, **k
partially update the specified MutatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_mutating_admission_policy_binding_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicyBinding (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the MutatingAdmissionPolicyBinding (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1alpha1MutatingAdmissionPolicyBinding, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1alpha1MutatingAdmissionPolicyBinding, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1617,7 +2050,10 @@ def patch_mutating_admission_policy_binding_with_http_info(self, name, body, **k
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1630,12 +2066,10 @@ def patch_mutating_admission_policy_binding_with_http_info(self, name, body, **k
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_mutating_admission_policy_binding`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_mutating_admission_policy_binding`") # noqa: E501
collection_formats = {}
@@ -1645,18 +2079,18 @@ def patch_mutating_admission_policy_binding_with_http_info(self, name, body, **k
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1669,12 +2103,22 @@ def patch_mutating_admission_policy_binding_with_http_info(self, name, body, **k
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1alpha1MutatingAdmissionPolicyBinding",
+ 201: "V1alpha1MutatingAdmissionPolicyBinding",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1alpha1/mutatingadmissionpolicybindings/{name}', 'PATCH',
path_params,
@@ -1683,13 +2127,14 @@ def patch_mutating_admission_policy_binding_with_http_info(self, name, body, **k
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1alpha1MutatingAdmissionPolicyBinding', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_mutating_admission_policy(self, name, **kwargs): # noqa: E501
"""read_mutating_admission_policy # noqa: E501
@@ -1697,22 +2142,28 @@ def read_mutating_admission_policy(self, name, **kwargs): # noqa: E501
read the specified MutatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_mutating_admission_policy(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicy (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the MutatingAdmissionPolicy (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1alpha1MutatingAdmissionPolicy
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1alpha1MutatingAdmissionPolicy
"""
kwargs['_return_http_data_only'] = True
return self.read_mutating_admission_policy_with_http_info(name, **kwargs) # noqa: E501
@@ -1723,24 +2174,36 @@ def read_mutating_admission_policy_with_http_info(self, name, **kwargs): # noqa
read the specified MutatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_mutating_admission_policy_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicy (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the MutatingAdmissionPolicy (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1alpha1MutatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1alpha1MutatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1754,7 +2217,10 @@ def read_mutating_admission_policy_with_http_info(self, name, **kwargs): # noqa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1767,8 +2233,7 @@ def read_mutating_admission_policy_with_http_info(self, name, **kwargs): # noqa
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_mutating_admission_policy`") # noqa: E501
collection_formats = {}
@@ -1778,10 +2243,10 @@ def read_mutating_admission_policy_with_http_info(self, name, **kwargs): # noqa
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1794,6 +2259,11 @@ def read_mutating_admission_policy_with_http_info(self, name, **kwargs): # noqa
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1alpha1MutatingAdmissionPolicy",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1alpha1/mutatingadmissionpolicies/{name}', 'GET',
path_params,
@@ -1802,13 +2272,14 @@ def read_mutating_admission_policy_with_http_info(self, name, **kwargs): # noqa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1alpha1MutatingAdmissionPolicy', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_mutating_admission_policy_binding(self, name, **kwargs): # noqa: E501
"""read_mutating_admission_policy_binding # noqa: E501
@@ -1816,22 +2287,28 @@ def read_mutating_admission_policy_binding(self, name, **kwargs): # noqa: E501
read the specified MutatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_mutating_admission_policy_binding(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicyBinding (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the MutatingAdmissionPolicyBinding (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1alpha1MutatingAdmissionPolicyBinding
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1alpha1MutatingAdmissionPolicyBinding
"""
kwargs['_return_http_data_only'] = True
return self.read_mutating_admission_policy_binding_with_http_info(name, **kwargs) # noqa: E501
@@ -1842,24 +2319,36 @@ def read_mutating_admission_policy_binding_with_http_info(self, name, **kwargs):
read the specified MutatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_mutating_admission_policy_binding_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicyBinding (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the MutatingAdmissionPolicyBinding (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1alpha1MutatingAdmissionPolicyBinding, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1alpha1MutatingAdmissionPolicyBinding, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1873,7 +2362,10 @@ def read_mutating_admission_policy_binding_with_http_info(self, name, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1886,8 +2378,7 @@ def read_mutating_admission_policy_binding_with_http_info(self, name, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_mutating_admission_policy_binding`") # noqa: E501
collection_formats = {}
@@ -1897,10 +2388,10 @@ def read_mutating_admission_policy_binding_with_http_info(self, name, **kwargs):
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1913,6 +2404,11 @@ def read_mutating_admission_policy_binding_with_http_info(self, name, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1alpha1MutatingAdmissionPolicyBinding",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1alpha1/mutatingadmissionpolicybindings/{name}', 'GET',
path_params,
@@ -1921,13 +2417,14 @@ def read_mutating_admission_policy_binding_with_http_info(self, name, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1alpha1MutatingAdmissionPolicyBinding', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_mutating_admission_policy(self, name, body, **kwargs): # noqa: E501
"""replace_mutating_admission_policy # noqa: E501
@@ -1935,26 +2432,36 @@ def replace_mutating_admission_policy(self, name, body, **kwargs): # noqa: E501
replace the specified MutatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_mutating_admission_policy(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicy (required)
- :param V1alpha1MutatingAdmissionPolicy body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the MutatingAdmissionPolicy (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1alpha1MutatingAdmissionPolicy
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1alpha1MutatingAdmissionPolicy
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1alpha1MutatingAdmissionPolicy
"""
kwargs['_return_http_data_only'] = True
return self.replace_mutating_admission_policy_with_http_info(name, body, **kwargs) # noqa: E501
@@ -1965,28 +2472,44 @@ def replace_mutating_admission_policy_with_http_info(self, name, body, **kwargs)
replace the specified MutatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_mutating_admission_policy_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicy (required)
- :param V1alpha1MutatingAdmissionPolicy body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the MutatingAdmissionPolicy (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1alpha1MutatingAdmissionPolicy
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1alpha1MutatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1alpha1MutatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2004,7 +2527,10 @@ def replace_mutating_admission_policy_with_http_info(self, name, body, **kwargs)
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2017,12 +2543,10 @@ def replace_mutating_admission_policy_with_http_info(self, name, body, **kwargs)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_mutating_admission_policy`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_mutating_admission_policy`") # noqa: E501
collection_formats = {}
@@ -2032,16 +2556,16 @@ def replace_mutating_admission_policy_with_http_info(self, name, body, **kwargs)
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2056,6 +2580,12 @@ def replace_mutating_admission_policy_with_http_info(self, name, body, **kwargs)
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1alpha1MutatingAdmissionPolicy",
+ 201: "V1alpha1MutatingAdmissionPolicy",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1alpha1/mutatingadmissionpolicies/{name}', 'PUT',
path_params,
@@ -2064,13 +2594,14 @@ def replace_mutating_admission_policy_with_http_info(self, name, body, **kwargs)
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1alpha1MutatingAdmissionPolicy', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_mutating_admission_policy_binding(self, name, body, **kwargs): # noqa: E501
"""replace_mutating_admission_policy_binding # noqa: E501
@@ -2078,26 +2609,36 @@ def replace_mutating_admission_policy_binding(self, name, body, **kwargs): # no
replace the specified MutatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_mutating_admission_policy_binding(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicyBinding (required)
- :param V1alpha1MutatingAdmissionPolicyBinding body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the MutatingAdmissionPolicyBinding (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1alpha1MutatingAdmissionPolicyBinding
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1alpha1MutatingAdmissionPolicyBinding
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1alpha1MutatingAdmissionPolicyBinding
"""
kwargs['_return_http_data_only'] = True
return self.replace_mutating_admission_policy_binding_with_http_info(name, body, **kwargs) # noqa: E501
@@ -2108,28 +2649,44 @@ def replace_mutating_admission_policy_binding_with_http_info(self, name, body, *
replace the specified MutatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_mutating_admission_policy_binding_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicyBinding (required)
- :param V1alpha1MutatingAdmissionPolicyBinding body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the MutatingAdmissionPolicyBinding (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1alpha1MutatingAdmissionPolicyBinding
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1alpha1MutatingAdmissionPolicyBinding, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1alpha1MutatingAdmissionPolicyBinding, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2147,7 +2704,10 @@ def replace_mutating_admission_policy_binding_with_http_info(self, name, body, *
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2160,12 +2720,10 @@ def replace_mutating_admission_policy_binding_with_http_info(self, name, body, *
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_mutating_admission_policy_binding`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_mutating_admission_policy_binding`") # noqa: E501
collection_formats = {}
@@ -2175,16 +2733,16 @@ def replace_mutating_admission_policy_binding_with_http_info(self, name, body, *
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2199,6 +2757,12 @@ def replace_mutating_admission_policy_binding_with_http_info(self, name, body, *
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1alpha1MutatingAdmissionPolicyBinding",
+ 201: "V1alpha1MutatingAdmissionPolicyBinding",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1alpha1/mutatingadmissionpolicybindings/{name}', 'PUT',
path_params,
@@ -2207,10 +2771,11 @@ def replace_mutating_admission_policy_binding_with_http_info(self, name, body, *
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1alpha1MutatingAdmissionPolicyBinding', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/admissionregistration_v1beta1_api.py b/kubernetes/client/api/admissionregistration_v1beta1_api.py
index 9fcc00d5f9..6ef1f8e409 100644
--- a/kubernetes/client/api/admissionregistration_v1beta1_api.py
+++ b/kubernetes/client/api/admissionregistration_v1beta1_api.py
@@ -42,25 +42,34 @@ def create_mutating_admission_policy(self, body, **kwargs): # noqa: E501
create a MutatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_mutating_admission_policy(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1beta1MutatingAdmissionPolicy body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1beta1MutatingAdmissionPolicy
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1MutatingAdmissionPolicy
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1MutatingAdmissionPolicy
"""
kwargs['_return_http_data_only'] = True
return self.create_mutating_admission_policy_with_http_info(body, **kwargs) # noqa: E501
@@ -71,27 +80,42 @@ def create_mutating_admission_policy_with_http_info(self, body, **kwargs): # no
create a MutatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_mutating_admission_policy_with_http_info(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1beta1MutatingAdmissionPolicy body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1beta1MutatingAdmissionPolicy
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1MutatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1MutatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -108,7 +132,10 @@ def create_mutating_admission_policy_with_http_info(self, body, **kwargs): # no
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -121,8 +148,7 @@ def create_mutating_admission_policy_with_http_info(self, body, **kwargs): # no
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_mutating_admission_policy`") # noqa: E501
collection_formats = {}
@@ -130,16 +156,16 @@ def create_mutating_admission_policy_with_http_info(self, body, **kwargs): # no
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -154,6 +180,13 @@ def create_mutating_admission_policy_with_http_info(self, body, **kwargs): # no
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1MutatingAdmissionPolicy",
+ 201: "V1beta1MutatingAdmissionPolicy",
+ 202: "V1beta1MutatingAdmissionPolicy",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1beta1/mutatingadmissionpolicies', 'POST',
path_params,
@@ -162,13 +195,14 @@ def create_mutating_admission_policy_with_http_info(self, body, **kwargs): # no
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1MutatingAdmissionPolicy', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_mutating_admission_policy_binding(self, body, **kwargs): # noqa: E501
"""create_mutating_admission_policy_binding # noqa: E501
@@ -176,25 +210,34 @@ def create_mutating_admission_policy_binding(self, body, **kwargs): # noqa: E50
create a MutatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_mutating_admission_policy_binding(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1beta1MutatingAdmissionPolicyBinding body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1beta1MutatingAdmissionPolicyBinding
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1MutatingAdmissionPolicyBinding
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1MutatingAdmissionPolicyBinding
"""
kwargs['_return_http_data_only'] = True
return self.create_mutating_admission_policy_binding_with_http_info(body, **kwargs) # noqa: E501
@@ -205,27 +248,42 @@ def create_mutating_admission_policy_binding_with_http_info(self, body, **kwargs
create a MutatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_mutating_admission_policy_binding_with_http_info(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1beta1MutatingAdmissionPolicyBinding body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1beta1MutatingAdmissionPolicyBinding
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1MutatingAdmissionPolicyBinding, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1MutatingAdmissionPolicyBinding, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -242,7 +300,10 @@ def create_mutating_admission_policy_binding_with_http_info(self, body, **kwargs
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -255,8 +316,7 @@ def create_mutating_admission_policy_binding_with_http_info(self, body, **kwargs
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_mutating_admission_policy_binding`") # noqa: E501
collection_formats = {}
@@ -264,16 +324,16 @@ def create_mutating_admission_policy_binding_with_http_info(self, body, **kwargs
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -288,6 +348,13 @@ def create_mutating_admission_policy_binding_with_http_info(self, body, **kwargs
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1MutatingAdmissionPolicyBinding",
+ 201: "V1beta1MutatingAdmissionPolicyBinding",
+ 202: "V1beta1MutatingAdmissionPolicyBinding",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1beta1/mutatingadmissionpolicybindings', 'POST',
path_params,
@@ -296,13 +363,14 @@ def create_mutating_admission_policy_binding_with_http_info(self, body, **kwargs
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1MutatingAdmissionPolicyBinding', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_mutating_admission_policy(self, **kwargs): # noqa: E501
"""delete_collection_mutating_admission_policy # noqa: E501
@@ -310,35 +378,54 @@ def delete_collection_mutating_admission_policy(self, **kwargs): # noqa: E501
delete collection of MutatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_mutating_admission_policy(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_mutating_admission_policy_with_http_info(**kwargs) # noqa: E501
@@ -349,37 +436,62 @@ def delete_collection_mutating_admission_policy_with_http_info(self, **kwargs):
delete collection of MutatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_mutating_admission_policy_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -406,7 +518,10 @@ def delete_collection_mutating_admission_policy_with_http_info(self, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -424,36 +539,36 @@ def delete_collection_mutating_admission_policy_with_http_info(self, **kwargs):
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -468,6 +583,11 @@ def delete_collection_mutating_admission_policy_with_http_info(self, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1beta1/mutatingadmissionpolicies', 'DELETE',
path_params,
@@ -476,13 +596,14 @@ def delete_collection_mutating_admission_policy_with_http_info(self, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_mutating_admission_policy_binding(self, **kwargs): # noqa: E501
"""delete_collection_mutating_admission_policy_binding # noqa: E501
@@ -490,35 +611,54 @@ def delete_collection_mutating_admission_policy_binding(self, **kwargs): # noqa
delete collection of MutatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_mutating_admission_policy_binding(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_mutating_admission_policy_binding_with_http_info(**kwargs) # noqa: E501
@@ -529,37 +669,62 @@ def delete_collection_mutating_admission_policy_binding_with_http_info(self, **k
delete collection of MutatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_mutating_admission_policy_binding_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -586,7 +751,10 @@ def delete_collection_mutating_admission_policy_binding_with_http_info(self, **k
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -604,36 +772,36 @@ def delete_collection_mutating_admission_policy_binding_with_http_info(self, **k
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -648,6 +816,11 @@ def delete_collection_mutating_admission_policy_binding_with_http_info(self, **k
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1beta1/mutatingadmissionpolicybindings', 'DELETE',
path_params,
@@ -656,13 +829,14 @@ def delete_collection_mutating_admission_policy_binding_with_http_info(self, **k
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_mutating_admission_policy(self, name, **kwargs): # noqa: E501
"""delete_mutating_admission_policy # noqa: E501
@@ -670,28 +844,40 @@ def delete_mutating_admission_policy(self, name, **kwargs): # noqa: E501
delete a MutatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_mutating_admission_policy(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicy (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the MutatingAdmissionPolicy (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_mutating_admission_policy_with_http_info(name, **kwargs) # noqa: E501
@@ -702,30 +888,48 @@ def delete_mutating_admission_policy_with_http_info(self, name, **kwargs): # no
delete a MutatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_mutating_admission_policy_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicy (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the MutatingAdmissionPolicy (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -745,7 +949,10 @@ def delete_mutating_admission_policy_with_http_info(self, name, **kwargs): # no
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -758,8 +965,7 @@ def delete_mutating_admission_policy_with_http_info(self, name, **kwargs): # no
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_mutating_admission_policy`") # noqa: E501
collection_formats = {}
@@ -769,20 +975,20 @@ def delete_mutating_admission_policy_with_http_info(self, name, **kwargs): # no
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -797,6 +1003,12 @@ def delete_mutating_admission_policy_with_http_info(self, name, **kwargs): # no
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1beta1/mutatingadmissionpolicies/{name}', 'DELETE',
path_params,
@@ -805,13 +1017,14 @@ def delete_mutating_admission_policy_with_http_info(self, name, **kwargs): # no
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_mutating_admission_policy_binding(self, name, **kwargs): # noqa: E501
"""delete_mutating_admission_policy_binding # noqa: E501
@@ -819,28 +1032,40 @@ def delete_mutating_admission_policy_binding(self, name, **kwargs): # noqa: E50
delete a MutatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_mutating_admission_policy_binding(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicyBinding (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the MutatingAdmissionPolicyBinding (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_mutating_admission_policy_binding_with_http_info(name, **kwargs) # noqa: E501
@@ -851,30 +1076,48 @@ def delete_mutating_admission_policy_binding_with_http_info(self, name, **kwargs
delete a MutatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_mutating_admission_policy_binding_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicyBinding (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the MutatingAdmissionPolicyBinding (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -894,7 +1137,10 @@ def delete_mutating_admission_policy_binding_with_http_info(self, name, **kwargs
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -907,8 +1153,7 @@ def delete_mutating_admission_policy_binding_with_http_info(self, name, **kwargs
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_mutating_admission_policy_binding`") # noqa: E501
collection_formats = {}
@@ -918,20 +1163,20 @@ def delete_mutating_admission_policy_binding_with_http_info(self, name, **kwargs
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -946,6 +1191,12 @@ def delete_mutating_admission_policy_binding_with_http_info(self, name, **kwargs
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1beta1/mutatingadmissionpolicybindings/{name}', 'DELETE',
path_params,
@@ -954,13 +1205,14 @@ def delete_mutating_admission_policy_binding_with_http_info(self, name, **kwargs
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def get_api_resources(self, **kwargs): # noqa: E501
"""get_api_resources # noqa: E501
@@ -968,20 +1220,24 @@ def get_api_resources(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIResourceList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIResourceList
"""
kwargs['_return_http_data_only'] = True
return self.get_api_resources_with_http_info(**kwargs) # noqa: E501
@@ -992,22 +1248,32 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1019,7 +1285,10 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1038,7 +1307,7 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1051,6 +1320,11 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIResourceList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1beta1/', 'GET',
path_params,
@@ -1059,13 +1333,14 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIResourceList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_mutating_admission_policy(self, **kwargs): # noqa: E501
"""list_mutating_admission_policy # noqa: E501
@@ -1073,31 +1348,46 @@ def list_mutating_admission_policy(self, **kwargs): # noqa: E501
list or watch objects of kind MutatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_mutating_admission_policy(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1MutatingAdmissionPolicyList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1MutatingAdmissionPolicyList
"""
kwargs['_return_http_data_only'] = True
return self.list_mutating_admission_policy_with_http_info(**kwargs) # noqa: E501
@@ -1108,33 +1398,54 @@ def list_mutating_admission_policy_with_http_info(self, **kwargs): # noqa: E501
list or watch objects of kind MutatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_mutating_admission_policy_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1MutatingAdmissionPolicyList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1MutatingAdmissionPolicyList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1157,7 +1468,10 @@ def list_mutating_admission_policy_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1175,30 +1489,30 @@ def list_mutating_admission_policy_with_http_info(self, **kwargs): # noqa: E501
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1211,6 +1525,11 @@ def list_mutating_admission_policy_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1MutatingAdmissionPolicyList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1beta1/mutatingadmissionpolicies', 'GET',
path_params,
@@ -1219,13 +1538,14 @@ def list_mutating_admission_policy_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1MutatingAdmissionPolicyList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_mutating_admission_policy_binding(self, **kwargs): # noqa: E501
"""list_mutating_admission_policy_binding # noqa: E501
@@ -1233,31 +1553,46 @@ def list_mutating_admission_policy_binding(self, **kwargs): # noqa: E501
list or watch objects of kind MutatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_mutating_admission_policy_binding(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1MutatingAdmissionPolicyBindingList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1MutatingAdmissionPolicyBindingList
"""
kwargs['_return_http_data_only'] = True
return self.list_mutating_admission_policy_binding_with_http_info(**kwargs) # noqa: E501
@@ -1268,33 +1603,54 @@ def list_mutating_admission_policy_binding_with_http_info(self, **kwargs): # no
list or watch objects of kind MutatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_mutating_admission_policy_binding_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1MutatingAdmissionPolicyBindingList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1MutatingAdmissionPolicyBindingList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1317,7 +1673,10 @@ def list_mutating_admission_policy_binding_with_http_info(self, **kwargs): # no
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1335,30 +1694,30 @@ def list_mutating_admission_policy_binding_with_http_info(self, **kwargs): # no
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1371,6 +1730,11 @@ def list_mutating_admission_policy_binding_with_http_info(self, **kwargs): # no
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1MutatingAdmissionPolicyBindingList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1beta1/mutatingadmissionpolicybindings', 'GET',
path_params,
@@ -1379,13 +1743,14 @@ def list_mutating_admission_policy_binding_with_http_info(self, **kwargs): # no
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1MutatingAdmissionPolicyBindingList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_mutating_admission_policy(self, name, body, **kwargs): # noqa: E501
"""patch_mutating_admission_policy # noqa: E501
@@ -1393,27 +1758,38 @@ def patch_mutating_admission_policy(self, name, body, **kwargs): # noqa: E501
partially update the specified MutatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_mutating_admission_policy(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicy (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the MutatingAdmissionPolicy (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1MutatingAdmissionPolicy
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1MutatingAdmissionPolicy
"""
kwargs['_return_http_data_only'] = True
return self.patch_mutating_admission_policy_with_http_info(name, body, **kwargs) # noqa: E501
@@ -1424,29 +1800,46 @@ def patch_mutating_admission_policy_with_http_info(self, name, body, **kwargs):
partially update the specified MutatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_mutating_admission_policy_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicy (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the MutatingAdmissionPolicy (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1MutatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1MutatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1465,7 +1858,10 @@ def patch_mutating_admission_policy_with_http_info(self, name, body, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1478,12 +1874,10 @@ def patch_mutating_admission_policy_with_http_info(self, name, body, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_mutating_admission_policy`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_mutating_admission_policy`") # noqa: E501
collection_formats = {}
@@ -1493,18 +1887,18 @@ def patch_mutating_admission_policy_with_http_info(self, name, body, **kwargs):
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1517,12 +1911,22 @@ def patch_mutating_admission_policy_with_http_info(self, name, body, **kwargs):
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1MutatingAdmissionPolicy",
+ 201: "V1beta1MutatingAdmissionPolicy",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1beta1/mutatingadmissionpolicies/{name}', 'PATCH',
path_params,
@@ -1531,13 +1935,14 @@ def patch_mutating_admission_policy_with_http_info(self, name, body, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1MutatingAdmissionPolicy', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_mutating_admission_policy_binding(self, name, body, **kwargs): # noqa: E501
"""patch_mutating_admission_policy_binding # noqa: E501
@@ -1545,27 +1950,38 @@ def patch_mutating_admission_policy_binding(self, name, body, **kwargs): # noqa
partially update the specified MutatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_mutating_admission_policy_binding(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicyBinding (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the MutatingAdmissionPolicyBinding (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1MutatingAdmissionPolicyBinding
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1MutatingAdmissionPolicyBinding
"""
kwargs['_return_http_data_only'] = True
return self.patch_mutating_admission_policy_binding_with_http_info(name, body, **kwargs) # noqa: E501
@@ -1576,29 +1992,46 @@ def patch_mutating_admission_policy_binding_with_http_info(self, name, body, **k
partially update the specified MutatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_mutating_admission_policy_binding_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicyBinding (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the MutatingAdmissionPolicyBinding (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1MutatingAdmissionPolicyBinding, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1MutatingAdmissionPolicyBinding, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1617,7 +2050,10 @@ def patch_mutating_admission_policy_binding_with_http_info(self, name, body, **k
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1630,12 +2066,10 @@ def patch_mutating_admission_policy_binding_with_http_info(self, name, body, **k
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_mutating_admission_policy_binding`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_mutating_admission_policy_binding`") # noqa: E501
collection_formats = {}
@@ -1645,18 +2079,18 @@ def patch_mutating_admission_policy_binding_with_http_info(self, name, body, **k
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1669,12 +2103,22 @@ def patch_mutating_admission_policy_binding_with_http_info(self, name, body, **k
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1MutatingAdmissionPolicyBinding",
+ 201: "V1beta1MutatingAdmissionPolicyBinding",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1beta1/mutatingadmissionpolicybindings/{name}', 'PATCH',
path_params,
@@ -1683,13 +2127,14 @@ def patch_mutating_admission_policy_binding_with_http_info(self, name, body, **k
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1MutatingAdmissionPolicyBinding', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_mutating_admission_policy(self, name, **kwargs): # noqa: E501
"""read_mutating_admission_policy # noqa: E501
@@ -1697,22 +2142,28 @@ def read_mutating_admission_policy(self, name, **kwargs): # noqa: E501
read the specified MutatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_mutating_admission_policy(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicy (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the MutatingAdmissionPolicy (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1MutatingAdmissionPolicy
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1MutatingAdmissionPolicy
"""
kwargs['_return_http_data_only'] = True
return self.read_mutating_admission_policy_with_http_info(name, **kwargs) # noqa: E501
@@ -1723,24 +2174,36 @@ def read_mutating_admission_policy_with_http_info(self, name, **kwargs): # noqa
read the specified MutatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_mutating_admission_policy_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicy (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the MutatingAdmissionPolicy (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1MutatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1MutatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1754,7 +2217,10 @@ def read_mutating_admission_policy_with_http_info(self, name, **kwargs): # noqa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1767,8 +2233,7 @@ def read_mutating_admission_policy_with_http_info(self, name, **kwargs): # noqa
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_mutating_admission_policy`") # noqa: E501
collection_formats = {}
@@ -1778,10 +2243,10 @@ def read_mutating_admission_policy_with_http_info(self, name, **kwargs): # noqa
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1794,6 +2259,11 @@ def read_mutating_admission_policy_with_http_info(self, name, **kwargs): # noqa
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1MutatingAdmissionPolicy",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1beta1/mutatingadmissionpolicies/{name}', 'GET',
path_params,
@@ -1802,13 +2272,14 @@ def read_mutating_admission_policy_with_http_info(self, name, **kwargs): # noqa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1MutatingAdmissionPolicy', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_mutating_admission_policy_binding(self, name, **kwargs): # noqa: E501
"""read_mutating_admission_policy_binding # noqa: E501
@@ -1816,22 +2287,28 @@ def read_mutating_admission_policy_binding(self, name, **kwargs): # noqa: E501
read the specified MutatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_mutating_admission_policy_binding(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicyBinding (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the MutatingAdmissionPolicyBinding (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1MutatingAdmissionPolicyBinding
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1MutatingAdmissionPolicyBinding
"""
kwargs['_return_http_data_only'] = True
return self.read_mutating_admission_policy_binding_with_http_info(name, **kwargs) # noqa: E501
@@ -1842,24 +2319,36 @@ def read_mutating_admission_policy_binding_with_http_info(self, name, **kwargs):
read the specified MutatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_mutating_admission_policy_binding_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicyBinding (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the MutatingAdmissionPolicyBinding (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1MutatingAdmissionPolicyBinding, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1MutatingAdmissionPolicyBinding, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1873,7 +2362,10 @@ def read_mutating_admission_policy_binding_with_http_info(self, name, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1886,8 +2378,7 @@ def read_mutating_admission_policy_binding_with_http_info(self, name, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_mutating_admission_policy_binding`") # noqa: E501
collection_formats = {}
@@ -1897,10 +2388,10 @@ def read_mutating_admission_policy_binding_with_http_info(self, name, **kwargs):
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1913,6 +2404,11 @@ def read_mutating_admission_policy_binding_with_http_info(self, name, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1MutatingAdmissionPolicyBinding",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1beta1/mutatingadmissionpolicybindings/{name}', 'GET',
path_params,
@@ -1921,13 +2417,14 @@ def read_mutating_admission_policy_binding_with_http_info(self, name, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1MutatingAdmissionPolicyBinding', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_mutating_admission_policy(self, name, body, **kwargs): # noqa: E501
"""replace_mutating_admission_policy # noqa: E501
@@ -1935,26 +2432,36 @@ def replace_mutating_admission_policy(self, name, body, **kwargs): # noqa: E501
replace the specified MutatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_mutating_admission_policy(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicy (required)
- :param V1beta1MutatingAdmissionPolicy body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the MutatingAdmissionPolicy (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1beta1MutatingAdmissionPolicy
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1MutatingAdmissionPolicy
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1MutatingAdmissionPolicy
"""
kwargs['_return_http_data_only'] = True
return self.replace_mutating_admission_policy_with_http_info(name, body, **kwargs) # noqa: E501
@@ -1965,28 +2472,44 @@ def replace_mutating_admission_policy_with_http_info(self, name, body, **kwargs)
replace the specified MutatingAdmissionPolicy # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_mutating_admission_policy_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicy (required)
- :param V1beta1MutatingAdmissionPolicy body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the MutatingAdmissionPolicy (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1beta1MutatingAdmissionPolicy
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1MutatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1MutatingAdmissionPolicy, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2004,7 +2527,10 @@ def replace_mutating_admission_policy_with_http_info(self, name, body, **kwargs)
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2017,12 +2543,10 @@ def replace_mutating_admission_policy_with_http_info(self, name, body, **kwargs)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_mutating_admission_policy`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_mutating_admission_policy`") # noqa: E501
collection_formats = {}
@@ -2032,16 +2556,16 @@ def replace_mutating_admission_policy_with_http_info(self, name, body, **kwargs)
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2056,6 +2580,12 @@ def replace_mutating_admission_policy_with_http_info(self, name, body, **kwargs)
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1MutatingAdmissionPolicy",
+ 201: "V1beta1MutatingAdmissionPolicy",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1beta1/mutatingadmissionpolicies/{name}', 'PUT',
path_params,
@@ -2064,13 +2594,14 @@ def replace_mutating_admission_policy_with_http_info(self, name, body, **kwargs)
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1MutatingAdmissionPolicy', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_mutating_admission_policy_binding(self, name, body, **kwargs): # noqa: E501
"""replace_mutating_admission_policy_binding # noqa: E501
@@ -2078,26 +2609,36 @@ def replace_mutating_admission_policy_binding(self, name, body, **kwargs): # no
replace the specified MutatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_mutating_admission_policy_binding(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicyBinding (required)
- :param V1beta1MutatingAdmissionPolicyBinding body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the MutatingAdmissionPolicyBinding (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1beta1MutatingAdmissionPolicyBinding
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1MutatingAdmissionPolicyBinding
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1MutatingAdmissionPolicyBinding
"""
kwargs['_return_http_data_only'] = True
return self.replace_mutating_admission_policy_binding_with_http_info(name, body, **kwargs) # noqa: E501
@@ -2108,28 +2649,44 @@ def replace_mutating_admission_policy_binding_with_http_info(self, name, body, *
replace the specified MutatingAdmissionPolicyBinding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_mutating_admission_policy_binding_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the MutatingAdmissionPolicyBinding (required)
- :param V1beta1MutatingAdmissionPolicyBinding body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the MutatingAdmissionPolicyBinding (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1beta1MutatingAdmissionPolicyBinding
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1MutatingAdmissionPolicyBinding, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1MutatingAdmissionPolicyBinding, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2147,7 +2704,10 @@ def replace_mutating_admission_policy_binding_with_http_info(self, name, body, *
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2160,12 +2720,10 @@ def replace_mutating_admission_policy_binding_with_http_info(self, name, body, *
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_mutating_admission_policy_binding`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_mutating_admission_policy_binding`") # noqa: E501
collection_formats = {}
@@ -2175,16 +2733,16 @@ def replace_mutating_admission_policy_binding_with_http_info(self, name, body, *
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2199,6 +2757,12 @@ def replace_mutating_admission_policy_binding_with_http_info(self, name, body, *
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1MutatingAdmissionPolicyBinding",
+ 201: "V1beta1MutatingAdmissionPolicyBinding",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/admissionregistration.k8s.io/v1beta1/mutatingadmissionpolicybindings/{name}', 'PUT',
path_params,
@@ -2207,10 +2771,11 @@ def replace_mutating_admission_policy_binding_with_http_info(self, name, body, *
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1MutatingAdmissionPolicyBinding', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/apiextensions_api.py b/kubernetes/client/api/apiextensions_api.py
index 3ffc26b5ec..359c066080 100644
--- a/kubernetes/client/api/apiextensions_api.py
+++ b/kubernetes/client/api/apiextensions_api.py
@@ -42,20 +42,24 @@ def get_api_group(self, **kwargs): # noqa: E501
get information of a group # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_group(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIGroup
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIGroup
"""
kwargs['_return_http_data_only'] = True
return self.get_api_group_with_http_info(**kwargs) # noqa: E501
@@ -66,22 +70,32 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
get information of a group # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_group_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIGroup, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIGroup, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -93,7 +107,10 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -112,7 +129,7 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -125,6 +142,11 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIGroup",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apiextensions.k8s.io/', 'GET',
path_params,
@@ -133,10 +155,11 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIGroup', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/apiextensions_v1_api.py b/kubernetes/client/api/apiextensions_v1_api.py
index 5e73868141..4dffef6be3 100644
--- a/kubernetes/client/api/apiextensions_v1_api.py
+++ b/kubernetes/client/api/apiextensions_v1_api.py
@@ -42,25 +42,34 @@ def create_custom_resource_definition(self, body, **kwargs): # noqa: E501
create a CustomResourceDefinition # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_custom_resource_definition(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1CustomResourceDefinition body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1CustomResourceDefinition
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1CustomResourceDefinition
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1CustomResourceDefinition
"""
kwargs['_return_http_data_only'] = True
return self.create_custom_resource_definition_with_http_info(body, **kwargs) # noqa: E501
@@ -71,27 +80,42 @@ def create_custom_resource_definition_with_http_info(self, body, **kwargs): # n
create a CustomResourceDefinition # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_custom_resource_definition_with_http_info(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1CustomResourceDefinition body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1CustomResourceDefinition
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1CustomResourceDefinition, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1CustomResourceDefinition, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -108,7 +132,10 @@ def create_custom_resource_definition_with_http_info(self, body, **kwargs): # n
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -121,8 +148,7 @@ def create_custom_resource_definition_with_http_info(self, body, **kwargs): # n
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_custom_resource_definition`") # noqa: E501
collection_formats = {}
@@ -130,16 +156,16 @@ def create_custom_resource_definition_with_http_info(self, body, **kwargs): # n
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -154,6 +180,13 @@ def create_custom_resource_definition_with_http_info(self, body, **kwargs): # n
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1CustomResourceDefinition",
+ 201: "V1CustomResourceDefinition",
+ 202: "V1CustomResourceDefinition",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apiextensions.k8s.io/v1/customresourcedefinitions', 'POST',
path_params,
@@ -162,13 +195,14 @@ def create_custom_resource_definition_with_http_info(self, body, **kwargs): # n
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1CustomResourceDefinition', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_custom_resource_definition(self, **kwargs): # noqa: E501
"""delete_collection_custom_resource_definition # noqa: E501
@@ -176,35 +210,54 @@ def delete_collection_custom_resource_definition(self, **kwargs): # noqa: E501
delete collection of CustomResourceDefinition # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_custom_resource_definition(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_custom_resource_definition_with_http_info(**kwargs) # noqa: E501
@@ -215,37 +268,62 @@ def delete_collection_custom_resource_definition_with_http_info(self, **kwargs):
delete collection of CustomResourceDefinition # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_custom_resource_definition_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -272,7 +350,10 @@ def delete_collection_custom_resource_definition_with_http_info(self, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -290,36 +371,36 @@ def delete_collection_custom_resource_definition_with_http_info(self, **kwargs):
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -334,6 +415,11 @@ def delete_collection_custom_resource_definition_with_http_info(self, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apiextensions.k8s.io/v1/customresourcedefinitions', 'DELETE',
path_params,
@@ -342,13 +428,14 @@ def delete_collection_custom_resource_definition_with_http_info(self, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_custom_resource_definition(self, name, **kwargs): # noqa: E501
"""delete_custom_resource_definition # noqa: E501
@@ -356,28 +443,40 @@ def delete_custom_resource_definition(self, name, **kwargs): # noqa: E501
delete a CustomResourceDefinition # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_custom_resource_definition(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CustomResourceDefinition (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the CustomResourceDefinition (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_custom_resource_definition_with_http_info(name, **kwargs) # noqa: E501
@@ -388,30 +487,48 @@ def delete_custom_resource_definition_with_http_info(self, name, **kwargs): # n
delete a CustomResourceDefinition # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_custom_resource_definition_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CustomResourceDefinition (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the CustomResourceDefinition (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -431,7 +548,10 @@ def delete_custom_resource_definition_with_http_info(self, name, **kwargs): # n
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -444,8 +564,7 @@ def delete_custom_resource_definition_with_http_info(self, name, **kwargs): # n
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_custom_resource_definition`") # noqa: E501
collection_formats = {}
@@ -455,20 +574,20 @@ def delete_custom_resource_definition_with_http_info(self, name, **kwargs): # n
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -483,6 +602,12 @@ def delete_custom_resource_definition_with_http_info(self, name, **kwargs): # n
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apiextensions.k8s.io/v1/customresourcedefinitions/{name}', 'DELETE',
path_params,
@@ -491,13 +616,14 @@ def delete_custom_resource_definition_with_http_info(self, name, **kwargs): # n
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def get_api_resources(self, **kwargs): # noqa: E501
"""get_api_resources # noqa: E501
@@ -505,20 +631,24 @@ def get_api_resources(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIResourceList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIResourceList
"""
kwargs['_return_http_data_only'] = True
return self.get_api_resources_with_http_info(**kwargs) # noqa: E501
@@ -529,22 +659,32 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -556,7 +696,10 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -575,7 +718,7 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -588,6 +731,11 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIResourceList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apiextensions.k8s.io/v1/', 'GET',
path_params,
@@ -596,13 +744,14 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIResourceList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_custom_resource_definition(self, **kwargs): # noqa: E501
"""list_custom_resource_definition # noqa: E501
@@ -610,31 +759,46 @@ def list_custom_resource_definition(self, **kwargs): # noqa: E501
list or watch objects of kind CustomResourceDefinition # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_custom_resource_definition(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1CustomResourceDefinitionList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1CustomResourceDefinitionList
"""
kwargs['_return_http_data_only'] = True
return self.list_custom_resource_definition_with_http_info(**kwargs) # noqa: E501
@@ -645,33 +809,54 @@ def list_custom_resource_definition_with_http_info(self, **kwargs): # noqa: E50
list or watch objects of kind CustomResourceDefinition # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_custom_resource_definition_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1CustomResourceDefinitionList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1CustomResourceDefinitionList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -694,7 +879,10 @@ def list_custom_resource_definition_with_http_info(self, **kwargs): # noqa: E50
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -712,30 +900,30 @@ def list_custom_resource_definition_with_http_info(self, **kwargs): # noqa: E50
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -748,6 +936,11 @@ def list_custom_resource_definition_with_http_info(self, **kwargs): # noqa: E50
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1CustomResourceDefinitionList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apiextensions.k8s.io/v1/customresourcedefinitions', 'GET',
path_params,
@@ -756,13 +949,14 @@ def list_custom_resource_definition_with_http_info(self, **kwargs): # noqa: E50
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1CustomResourceDefinitionList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_custom_resource_definition(self, name, body, **kwargs): # noqa: E501
"""patch_custom_resource_definition # noqa: E501
@@ -770,27 +964,38 @@ def patch_custom_resource_definition(self, name, body, **kwargs): # noqa: E501
partially update the specified CustomResourceDefinition # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_custom_resource_definition(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CustomResourceDefinition (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the CustomResourceDefinition (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1CustomResourceDefinition
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1CustomResourceDefinition
"""
kwargs['_return_http_data_only'] = True
return self.patch_custom_resource_definition_with_http_info(name, body, **kwargs) # noqa: E501
@@ -801,29 +1006,46 @@ def patch_custom_resource_definition_with_http_info(self, name, body, **kwargs):
partially update the specified CustomResourceDefinition # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_custom_resource_definition_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CustomResourceDefinition (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the CustomResourceDefinition (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1CustomResourceDefinition, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1CustomResourceDefinition, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -842,7 +1064,10 @@ def patch_custom_resource_definition_with_http_info(self, name, body, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -855,12 +1080,10 @@ def patch_custom_resource_definition_with_http_info(self, name, body, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_custom_resource_definition`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_custom_resource_definition`") # noqa: E501
collection_formats = {}
@@ -870,18 +1093,18 @@ def patch_custom_resource_definition_with_http_info(self, name, body, **kwargs):
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -894,12 +1117,22 @@ def patch_custom_resource_definition_with_http_info(self, name, body, **kwargs):
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1CustomResourceDefinition",
+ 201: "V1CustomResourceDefinition",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apiextensions.k8s.io/v1/customresourcedefinitions/{name}', 'PATCH',
path_params,
@@ -908,13 +1141,14 @@ def patch_custom_resource_definition_with_http_info(self, name, body, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1CustomResourceDefinition', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_custom_resource_definition_status(self, name, body, **kwargs): # noqa: E501
"""patch_custom_resource_definition_status # noqa: E501
@@ -922,27 +1156,38 @@ def patch_custom_resource_definition_status(self, name, body, **kwargs): # noqa
partially update status of the specified CustomResourceDefinition # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_custom_resource_definition_status(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CustomResourceDefinition (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the CustomResourceDefinition (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1CustomResourceDefinition
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1CustomResourceDefinition
"""
kwargs['_return_http_data_only'] = True
return self.patch_custom_resource_definition_status_with_http_info(name, body, **kwargs) # noqa: E501
@@ -953,29 +1198,46 @@ def patch_custom_resource_definition_status_with_http_info(self, name, body, **k
partially update status of the specified CustomResourceDefinition # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_custom_resource_definition_status_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CustomResourceDefinition (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the CustomResourceDefinition (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1CustomResourceDefinition, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1CustomResourceDefinition, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -994,7 +1256,10 @@ def patch_custom_resource_definition_status_with_http_info(self, name, body, **k
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1007,12 +1272,10 @@ def patch_custom_resource_definition_status_with_http_info(self, name, body, **k
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_custom_resource_definition_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_custom_resource_definition_status`") # noqa: E501
collection_formats = {}
@@ -1022,18 +1285,18 @@ def patch_custom_resource_definition_status_with_http_info(self, name, body, **k
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1046,12 +1309,22 @@ def patch_custom_resource_definition_status_with_http_info(self, name, body, **k
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1CustomResourceDefinition",
+ 201: "V1CustomResourceDefinition",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apiextensions.k8s.io/v1/customresourcedefinitions/{name}/status', 'PATCH',
path_params,
@@ -1060,13 +1333,14 @@ def patch_custom_resource_definition_status_with_http_info(self, name, body, **k
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1CustomResourceDefinition', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_custom_resource_definition(self, name, **kwargs): # noqa: E501
"""read_custom_resource_definition # noqa: E501
@@ -1074,22 +1348,28 @@ def read_custom_resource_definition(self, name, **kwargs): # noqa: E501
read the specified CustomResourceDefinition # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_custom_resource_definition(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CustomResourceDefinition (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the CustomResourceDefinition (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1CustomResourceDefinition
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1CustomResourceDefinition
"""
kwargs['_return_http_data_only'] = True
return self.read_custom_resource_definition_with_http_info(name, **kwargs) # noqa: E501
@@ -1100,24 +1380,36 @@ def read_custom_resource_definition_with_http_info(self, name, **kwargs): # noq
read the specified CustomResourceDefinition # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_custom_resource_definition_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CustomResourceDefinition (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the CustomResourceDefinition (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1CustomResourceDefinition, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1CustomResourceDefinition, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1131,7 +1423,10 @@ def read_custom_resource_definition_with_http_info(self, name, **kwargs): # noq
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1144,8 +1439,7 @@ def read_custom_resource_definition_with_http_info(self, name, **kwargs): # noq
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_custom_resource_definition`") # noqa: E501
collection_formats = {}
@@ -1155,10 +1449,10 @@ def read_custom_resource_definition_with_http_info(self, name, **kwargs): # noq
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1171,6 +1465,11 @@ def read_custom_resource_definition_with_http_info(self, name, **kwargs): # noq
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1CustomResourceDefinition",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apiextensions.k8s.io/v1/customresourcedefinitions/{name}', 'GET',
path_params,
@@ -1179,13 +1478,14 @@ def read_custom_resource_definition_with_http_info(self, name, **kwargs): # noq
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1CustomResourceDefinition', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_custom_resource_definition_status(self, name, **kwargs): # noqa: E501
"""read_custom_resource_definition_status # noqa: E501
@@ -1193,22 +1493,28 @@ def read_custom_resource_definition_status(self, name, **kwargs): # noqa: E501
read status of the specified CustomResourceDefinition # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_custom_resource_definition_status(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CustomResourceDefinition (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the CustomResourceDefinition (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1CustomResourceDefinition
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1CustomResourceDefinition
"""
kwargs['_return_http_data_only'] = True
return self.read_custom_resource_definition_status_with_http_info(name, **kwargs) # noqa: E501
@@ -1219,24 +1525,36 @@ def read_custom_resource_definition_status_with_http_info(self, name, **kwargs):
read status of the specified CustomResourceDefinition # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_custom_resource_definition_status_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CustomResourceDefinition (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the CustomResourceDefinition (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1CustomResourceDefinition, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1CustomResourceDefinition, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1250,7 +1568,10 @@ def read_custom_resource_definition_status_with_http_info(self, name, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1263,8 +1584,7 @@ def read_custom_resource_definition_status_with_http_info(self, name, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_custom_resource_definition_status`") # noqa: E501
collection_formats = {}
@@ -1274,10 +1594,10 @@ def read_custom_resource_definition_status_with_http_info(self, name, **kwargs):
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1290,6 +1610,11 @@ def read_custom_resource_definition_status_with_http_info(self, name, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1CustomResourceDefinition",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apiextensions.k8s.io/v1/customresourcedefinitions/{name}/status', 'GET',
path_params,
@@ -1298,13 +1623,14 @@ def read_custom_resource_definition_status_with_http_info(self, name, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1CustomResourceDefinition', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_custom_resource_definition(self, name, body, **kwargs): # noqa: E501
"""replace_custom_resource_definition # noqa: E501
@@ -1312,26 +1638,36 @@ def replace_custom_resource_definition(self, name, body, **kwargs): # noqa: E50
replace the specified CustomResourceDefinition # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_custom_resource_definition(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CustomResourceDefinition (required)
- :param V1CustomResourceDefinition body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the CustomResourceDefinition (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1CustomResourceDefinition
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1CustomResourceDefinition
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1CustomResourceDefinition
"""
kwargs['_return_http_data_only'] = True
return self.replace_custom_resource_definition_with_http_info(name, body, **kwargs) # noqa: E501
@@ -1342,28 +1678,44 @@ def replace_custom_resource_definition_with_http_info(self, name, body, **kwargs
replace the specified CustomResourceDefinition # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_custom_resource_definition_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CustomResourceDefinition (required)
- :param V1CustomResourceDefinition body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the CustomResourceDefinition (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1CustomResourceDefinition
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1CustomResourceDefinition, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1CustomResourceDefinition, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1381,7 +1733,10 @@ def replace_custom_resource_definition_with_http_info(self, name, body, **kwargs
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1394,12 +1749,10 @@ def replace_custom_resource_definition_with_http_info(self, name, body, **kwargs
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_custom_resource_definition`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_custom_resource_definition`") # noqa: E501
collection_formats = {}
@@ -1409,16 +1762,16 @@ def replace_custom_resource_definition_with_http_info(self, name, body, **kwargs
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1433,6 +1786,12 @@ def replace_custom_resource_definition_with_http_info(self, name, body, **kwargs
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1CustomResourceDefinition",
+ 201: "V1CustomResourceDefinition",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apiextensions.k8s.io/v1/customresourcedefinitions/{name}', 'PUT',
path_params,
@@ -1441,13 +1800,14 @@ def replace_custom_resource_definition_with_http_info(self, name, body, **kwargs
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1CustomResourceDefinition', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_custom_resource_definition_status(self, name, body, **kwargs): # noqa: E501
"""replace_custom_resource_definition_status # noqa: E501
@@ -1455,26 +1815,36 @@ def replace_custom_resource_definition_status(self, name, body, **kwargs): # no
replace status of the specified CustomResourceDefinition # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_custom_resource_definition_status(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CustomResourceDefinition (required)
- :param V1CustomResourceDefinition body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the CustomResourceDefinition (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1CustomResourceDefinition
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1CustomResourceDefinition
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1CustomResourceDefinition
"""
kwargs['_return_http_data_only'] = True
return self.replace_custom_resource_definition_status_with_http_info(name, body, **kwargs) # noqa: E501
@@ -1485,28 +1855,44 @@ def replace_custom_resource_definition_status_with_http_info(self, name, body, *
replace status of the specified CustomResourceDefinition # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_custom_resource_definition_status_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CustomResourceDefinition (required)
- :param V1CustomResourceDefinition body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the CustomResourceDefinition (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1CustomResourceDefinition
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1CustomResourceDefinition, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1CustomResourceDefinition, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1524,7 +1910,10 @@ def replace_custom_resource_definition_status_with_http_info(self, name, body, *
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1537,12 +1926,10 @@ def replace_custom_resource_definition_status_with_http_info(self, name, body, *
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_custom_resource_definition_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_custom_resource_definition_status`") # noqa: E501
collection_formats = {}
@@ -1552,16 +1939,16 @@ def replace_custom_resource_definition_status_with_http_info(self, name, body, *
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1576,6 +1963,12 @@ def replace_custom_resource_definition_status_with_http_info(self, name, body, *
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1CustomResourceDefinition",
+ 201: "V1CustomResourceDefinition",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apiextensions.k8s.io/v1/customresourcedefinitions/{name}/status', 'PUT',
path_params,
@@ -1584,10 +1977,11 @@ def replace_custom_resource_definition_status_with_http_info(self, name, body, *
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1CustomResourceDefinition', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/apiregistration_api.py b/kubernetes/client/api/apiregistration_api.py
index 1bb435a00b..7bde8eadbc 100644
--- a/kubernetes/client/api/apiregistration_api.py
+++ b/kubernetes/client/api/apiregistration_api.py
@@ -42,20 +42,24 @@ def get_api_group(self, **kwargs): # noqa: E501
get information of a group # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_group(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIGroup
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIGroup
"""
kwargs['_return_http_data_only'] = True
return self.get_api_group_with_http_info(**kwargs) # noqa: E501
@@ -66,22 +70,32 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
get information of a group # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_group_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIGroup, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIGroup, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -93,7 +107,10 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -112,7 +129,7 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -125,6 +142,11 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIGroup",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apiregistration.k8s.io/', 'GET',
path_params,
@@ -133,10 +155,11 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIGroup', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/apiregistration_v1_api.py b/kubernetes/client/api/apiregistration_v1_api.py
index 63ef4eaad8..ac6915efde 100644
--- a/kubernetes/client/api/apiregistration_v1_api.py
+++ b/kubernetes/client/api/apiregistration_v1_api.py
@@ -42,25 +42,34 @@ def create_api_service(self, body, **kwargs): # noqa: E501
create an APIService # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_api_service(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1APIService body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1APIService
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIService
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIService
"""
kwargs['_return_http_data_only'] = True
return self.create_api_service_with_http_info(body, **kwargs) # noqa: E501
@@ -71,27 +80,42 @@ def create_api_service_with_http_info(self, body, **kwargs): # noqa: E501
create an APIService # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_api_service_with_http_info(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1APIService body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1APIService
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIService, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIService, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -108,7 +132,10 @@ def create_api_service_with_http_info(self, body, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -121,8 +148,7 @@ def create_api_service_with_http_info(self, body, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_api_service`") # noqa: E501
collection_formats = {}
@@ -130,16 +156,16 @@ def create_api_service_with_http_info(self, body, **kwargs): # noqa: E501
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -154,6 +180,13 @@ def create_api_service_with_http_info(self, body, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIService",
+ 201: "V1APIService",
+ 202: "V1APIService",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apiregistration.k8s.io/v1/apiservices', 'POST',
path_params,
@@ -162,13 +195,14 @@ def create_api_service_with_http_info(self, body, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIService', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_api_service(self, name, **kwargs): # noqa: E501
"""delete_api_service # noqa: E501
@@ -176,28 +210,40 @@ def delete_api_service(self, name, **kwargs): # noqa: E501
delete an APIService # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_api_service(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the APIService (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the APIService (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_api_service_with_http_info(name, **kwargs) # noqa: E501
@@ -208,30 +254,48 @@ def delete_api_service_with_http_info(self, name, **kwargs): # noqa: E501
delete an APIService # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_api_service_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the APIService (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the APIService (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -251,7 +315,10 @@ def delete_api_service_with_http_info(self, name, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -264,8 +331,7 @@ def delete_api_service_with_http_info(self, name, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_api_service`") # noqa: E501
collection_formats = {}
@@ -275,20 +341,20 @@ def delete_api_service_with_http_info(self, name, **kwargs): # noqa: E501
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -303,6 +369,12 @@ def delete_api_service_with_http_info(self, name, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apiregistration.k8s.io/v1/apiservices/{name}', 'DELETE',
path_params,
@@ -311,13 +383,14 @@ def delete_api_service_with_http_info(self, name, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_api_service(self, **kwargs): # noqa: E501
"""delete_collection_api_service # noqa: E501
@@ -325,35 +398,54 @@ def delete_collection_api_service(self, **kwargs): # noqa: E501
delete collection of APIService # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_api_service(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_api_service_with_http_info(**kwargs) # noqa: E501
@@ -364,37 +456,62 @@ def delete_collection_api_service_with_http_info(self, **kwargs): # noqa: E501
delete collection of APIService # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_api_service_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -421,7 +538,10 @@ def delete_collection_api_service_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -439,36 +559,36 @@ def delete_collection_api_service_with_http_info(self, **kwargs): # noqa: E501
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -483,6 +603,11 @@ def delete_collection_api_service_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apiregistration.k8s.io/v1/apiservices', 'DELETE',
path_params,
@@ -491,13 +616,14 @@ def delete_collection_api_service_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def get_api_resources(self, **kwargs): # noqa: E501
"""get_api_resources # noqa: E501
@@ -505,20 +631,24 @@ def get_api_resources(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIResourceList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIResourceList
"""
kwargs['_return_http_data_only'] = True
return self.get_api_resources_with_http_info(**kwargs) # noqa: E501
@@ -529,22 +659,32 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -556,7 +696,10 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -575,7 +718,7 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -588,6 +731,11 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIResourceList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apiregistration.k8s.io/v1/', 'GET',
path_params,
@@ -596,13 +744,14 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIResourceList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_api_service(self, **kwargs): # noqa: E501
"""list_api_service # noqa: E501
@@ -610,31 +759,46 @@ def list_api_service(self, **kwargs): # noqa: E501
list or watch objects of kind APIService # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_api_service(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIServiceList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIServiceList
"""
kwargs['_return_http_data_only'] = True
return self.list_api_service_with_http_info(**kwargs) # noqa: E501
@@ -645,33 +809,54 @@ def list_api_service_with_http_info(self, **kwargs): # noqa: E501
list or watch objects of kind APIService # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_api_service_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIServiceList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIServiceList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -694,7 +879,10 @@ def list_api_service_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -712,30 +900,30 @@ def list_api_service_with_http_info(self, **kwargs): # noqa: E501
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -748,6 +936,11 @@ def list_api_service_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIServiceList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apiregistration.k8s.io/v1/apiservices', 'GET',
path_params,
@@ -756,13 +949,14 @@ def list_api_service_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIServiceList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_api_service(self, name, body, **kwargs): # noqa: E501
"""patch_api_service # noqa: E501
@@ -770,27 +964,38 @@ def patch_api_service(self, name, body, **kwargs): # noqa: E501
partially update the specified APIService # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_api_service(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the APIService (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the APIService (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIService
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIService
"""
kwargs['_return_http_data_only'] = True
return self.patch_api_service_with_http_info(name, body, **kwargs) # noqa: E501
@@ -801,29 +1006,46 @@ def patch_api_service_with_http_info(self, name, body, **kwargs): # noqa: E501
partially update the specified APIService # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_api_service_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the APIService (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the APIService (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIService, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIService, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -842,7 +1064,10 @@ def patch_api_service_with_http_info(self, name, body, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -855,12 +1080,10 @@ def patch_api_service_with_http_info(self, name, body, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_api_service`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_api_service`") # noqa: E501
collection_formats = {}
@@ -870,18 +1093,18 @@ def patch_api_service_with_http_info(self, name, body, **kwargs): # noqa: E501
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -894,12 +1117,22 @@ def patch_api_service_with_http_info(self, name, body, **kwargs): # noqa: E501
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIService",
+ 201: "V1APIService",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apiregistration.k8s.io/v1/apiservices/{name}', 'PATCH',
path_params,
@@ -908,13 +1141,14 @@ def patch_api_service_with_http_info(self, name, body, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIService', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_api_service_status(self, name, body, **kwargs): # noqa: E501
"""patch_api_service_status # noqa: E501
@@ -922,27 +1156,38 @@ def patch_api_service_status(self, name, body, **kwargs): # noqa: E501
partially update status of the specified APIService # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_api_service_status(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the APIService (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the APIService (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIService
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIService
"""
kwargs['_return_http_data_only'] = True
return self.patch_api_service_status_with_http_info(name, body, **kwargs) # noqa: E501
@@ -953,29 +1198,46 @@ def patch_api_service_status_with_http_info(self, name, body, **kwargs): # noqa
partially update status of the specified APIService # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_api_service_status_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the APIService (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the APIService (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIService, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIService, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -994,7 +1256,10 @@ def patch_api_service_status_with_http_info(self, name, body, **kwargs): # noqa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1007,12 +1272,10 @@ def patch_api_service_status_with_http_info(self, name, body, **kwargs): # noqa
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_api_service_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_api_service_status`") # noqa: E501
collection_formats = {}
@@ -1022,18 +1285,18 @@ def patch_api_service_status_with_http_info(self, name, body, **kwargs): # noqa
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1046,12 +1309,22 @@ def patch_api_service_status_with_http_info(self, name, body, **kwargs): # noqa
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIService",
+ 201: "V1APIService",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apiregistration.k8s.io/v1/apiservices/{name}/status', 'PATCH',
path_params,
@@ -1060,13 +1333,14 @@ def patch_api_service_status_with_http_info(self, name, body, **kwargs): # noqa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIService', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_api_service(self, name, **kwargs): # noqa: E501
"""read_api_service # noqa: E501
@@ -1074,22 +1348,28 @@ def read_api_service(self, name, **kwargs): # noqa: E501
read the specified APIService # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_api_service(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the APIService (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the APIService (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIService
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIService
"""
kwargs['_return_http_data_only'] = True
return self.read_api_service_with_http_info(name, **kwargs) # noqa: E501
@@ -1100,24 +1380,36 @@ def read_api_service_with_http_info(self, name, **kwargs): # noqa: E501
read the specified APIService # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_api_service_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the APIService (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the APIService (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIService, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIService, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1131,7 +1423,10 @@ def read_api_service_with_http_info(self, name, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1144,8 +1439,7 @@ def read_api_service_with_http_info(self, name, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_api_service`") # noqa: E501
collection_formats = {}
@@ -1155,10 +1449,10 @@ def read_api_service_with_http_info(self, name, **kwargs): # noqa: E501
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1171,6 +1465,11 @@ def read_api_service_with_http_info(self, name, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIService",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apiregistration.k8s.io/v1/apiservices/{name}', 'GET',
path_params,
@@ -1179,13 +1478,14 @@ def read_api_service_with_http_info(self, name, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIService', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_api_service_status(self, name, **kwargs): # noqa: E501
"""read_api_service_status # noqa: E501
@@ -1193,22 +1493,28 @@ def read_api_service_status(self, name, **kwargs): # noqa: E501
read status of the specified APIService # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_api_service_status(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the APIService (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the APIService (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIService
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIService
"""
kwargs['_return_http_data_only'] = True
return self.read_api_service_status_with_http_info(name, **kwargs) # noqa: E501
@@ -1219,24 +1525,36 @@ def read_api_service_status_with_http_info(self, name, **kwargs): # noqa: E501
read status of the specified APIService # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_api_service_status_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the APIService (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the APIService (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIService, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIService, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1250,7 +1568,10 @@ def read_api_service_status_with_http_info(self, name, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1263,8 +1584,7 @@ def read_api_service_status_with_http_info(self, name, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_api_service_status`") # noqa: E501
collection_formats = {}
@@ -1274,10 +1594,10 @@ def read_api_service_status_with_http_info(self, name, **kwargs): # noqa: E501
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1290,6 +1610,11 @@ def read_api_service_status_with_http_info(self, name, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIService",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apiregistration.k8s.io/v1/apiservices/{name}/status', 'GET',
path_params,
@@ -1298,13 +1623,14 @@ def read_api_service_status_with_http_info(self, name, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIService', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_api_service(self, name, body, **kwargs): # noqa: E501
"""replace_api_service # noqa: E501
@@ -1312,26 +1638,36 @@ def replace_api_service(self, name, body, **kwargs): # noqa: E501
replace the specified APIService # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_api_service(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the APIService (required)
- :param V1APIService body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the APIService (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1APIService
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIService
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIService
"""
kwargs['_return_http_data_only'] = True
return self.replace_api_service_with_http_info(name, body, **kwargs) # noqa: E501
@@ -1342,28 +1678,44 @@ def replace_api_service_with_http_info(self, name, body, **kwargs): # noqa: E50
replace the specified APIService # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_api_service_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the APIService (required)
- :param V1APIService body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the APIService (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1APIService
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIService, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIService, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1381,7 +1733,10 @@ def replace_api_service_with_http_info(self, name, body, **kwargs): # noqa: E50
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1394,12 +1749,10 @@ def replace_api_service_with_http_info(self, name, body, **kwargs): # noqa: E50
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_api_service`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_api_service`") # noqa: E501
collection_formats = {}
@@ -1409,16 +1762,16 @@ def replace_api_service_with_http_info(self, name, body, **kwargs): # noqa: E50
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1433,6 +1786,12 @@ def replace_api_service_with_http_info(self, name, body, **kwargs): # noqa: E50
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIService",
+ 201: "V1APIService",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apiregistration.k8s.io/v1/apiservices/{name}', 'PUT',
path_params,
@@ -1441,13 +1800,14 @@ def replace_api_service_with_http_info(self, name, body, **kwargs): # noqa: E50
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIService', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_api_service_status(self, name, body, **kwargs): # noqa: E501
"""replace_api_service_status # noqa: E501
@@ -1455,26 +1815,36 @@ def replace_api_service_status(self, name, body, **kwargs): # noqa: E501
replace status of the specified APIService # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_api_service_status(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the APIService (required)
- :param V1APIService body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the APIService (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1APIService
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIService
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIService
"""
kwargs['_return_http_data_only'] = True
return self.replace_api_service_status_with_http_info(name, body, **kwargs) # noqa: E501
@@ -1485,28 +1855,44 @@ def replace_api_service_status_with_http_info(self, name, body, **kwargs): # no
replace status of the specified APIService # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_api_service_status_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the APIService (required)
- :param V1APIService body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the APIService (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1APIService
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIService, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIService, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1524,7 +1910,10 @@ def replace_api_service_status_with_http_info(self, name, body, **kwargs): # no
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1537,12 +1926,10 @@ def replace_api_service_status_with_http_info(self, name, body, **kwargs): # no
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_api_service_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_api_service_status`") # noqa: E501
collection_formats = {}
@@ -1552,16 +1939,16 @@ def replace_api_service_status_with_http_info(self, name, body, **kwargs): # no
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1576,6 +1963,12 @@ def replace_api_service_status_with_http_info(self, name, body, **kwargs): # no
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIService",
+ 201: "V1APIService",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apiregistration.k8s.io/v1/apiservices/{name}/status', 'PUT',
path_params,
@@ -1584,10 +1977,11 @@ def replace_api_service_status_with_http_info(self, name, body, **kwargs): # no
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIService', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/apis_api.py b/kubernetes/client/api/apis_api.py
index 850b9770d7..dc0d461dea 100644
--- a/kubernetes/client/api/apis_api.py
+++ b/kubernetes/client/api/apis_api.py
@@ -42,20 +42,24 @@ def get_api_versions(self, **kwargs): # noqa: E501
get available API versions # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_versions(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIGroupList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIGroupList
"""
kwargs['_return_http_data_only'] = True
return self.get_api_versions_with_http_info(**kwargs) # noqa: E501
@@ -66,22 +70,32 @@ def get_api_versions_with_http_info(self, **kwargs): # noqa: E501
get available API versions # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_versions_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIGroupList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIGroupList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -93,7 +107,10 @@ def get_api_versions_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -112,7 +129,7 @@ def get_api_versions_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -125,6 +142,11 @@ def get_api_versions_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIGroupList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/', 'GET',
path_params,
@@ -133,10 +155,11 @@ def get_api_versions_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIGroupList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/apps_api.py b/kubernetes/client/api/apps_api.py
index 05dbaf0166..e69b3c8533 100644
--- a/kubernetes/client/api/apps_api.py
+++ b/kubernetes/client/api/apps_api.py
@@ -42,20 +42,24 @@ def get_api_group(self, **kwargs): # noqa: E501
get information of a group # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_group(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIGroup
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIGroup
"""
kwargs['_return_http_data_only'] = True
return self.get_api_group_with_http_info(**kwargs) # noqa: E501
@@ -66,22 +70,32 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
get information of a group # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_group_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIGroup, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIGroup, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -93,7 +107,10 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -112,7 +129,7 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -125,6 +142,11 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIGroup",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/', 'GET',
path_params,
@@ -133,10 +155,11 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIGroup', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/apps_v1_api.py b/kubernetes/client/api/apps_v1_api.py
index 9b373fea32..06bba034df 100644
--- a/kubernetes/client/api/apps_v1_api.py
+++ b/kubernetes/client/api/apps_v1_api.py
@@ -42,26 +42,36 @@ def create_namespaced_controller_revision(self, namespace, body, **kwargs): # n
create a ControllerRevision # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_controller_revision(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ControllerRevision body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ControllerRevision
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ControllerRevision
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ControllerRevision
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_controller_revision_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -72,28 +82,44 @@ def create_namespaced_controller_revision_with_http_info(self, namespace, body,
create a ControllerRevision # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_controller_revision_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ControllerRevision body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ControllerRevision
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ControllerRevision, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ControllerRevision, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -111,7 +137,10 @@ def create_namespaced_controller_revision_with_http_info(self, namespace, body,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -124,12 +153,10 @@ def create_namespaced_controller_revision_with_http_info(self, namespace, body,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_controller_revision`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_controller_revision`") # noqa: E501
collection_formats = {}
@@ -139,16 +166,16 @@ def create_namespaced_controller_revision_with_http_info(self, namespace, body,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -163,6 +190,13 @@ def create_namespaced_controller_revision_with_http_info(self, namespace, body,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ControllerRevision",
+ 201: "V1ControllerRevision",
+ 202: "V1ControllerRevision",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/controllerrevisions', 'POST',
path_params,
@@ -171,13 +205,14 @@ def create_namespaced_controller_revision_with_http_info(self, namespace, body,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ControllerRevision', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_namespaced_daemon_set(self, namespace, body, **kwargs): # noqa: E501
"""create_namespaced_daemon_set # noqa: E501
@@ -185,26 +220,36 @@ def create_namespaced_daemon_set(self, namespace, body, **kwargs): # noqa: E501
create a DaemonSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_daemon_set(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1DaemonSet body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1DaemonSet
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1DaemonSet
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1DaemonSet
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_daemon_set_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -215,28 +260,44 @@ def create_namespaced_daemon_set_with_http_info(self, namespace, body, **kwargs)
create a DaemonSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_daemon_set_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1DaemonSet body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1DaemonSet
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1DaemonSet, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1DaemonSet, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -254,7 +315,10 @@ def create_namespaced_daemon_set_with_http_info(self, namespace, body, **kwargs)
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -267,12 +331,10 @@ def create_namespaced_daemon_set_with_http_info(self, namespace, body, **kwargs)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_daemon_set`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_daemon_set`") # noqa: E501
collection_formats = {}
@@ -282,16 +344,16 @@ def create_namespaced_daemon_set_with_http_info(self, namespace, body, **kwargs)
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -306,6 +368,13 @@ def create_namespaced_daemon_set_with_http_info(self, namespace, body, **kwargs)
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1DaemonSet",
+ 201: "V1DaemonSet",
+ 202: "V1DaemonSet",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/daemonsets', 'POST',
path_params,
@@ -314,13 +383,14 @@ def create_namespaced_daemon_set_with_http_info(self, namespace, body, **kwargs)
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1DaemonSet', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_namespaced_deployment(self, namespace, body, **kwargs): # noqa: E501
"""create_namespaced_deployment # noqa: E501
@@ -328,26 +398,36 @@ def create_namespaced_deployment(self, namespace, body, **kwargs): # noqa: E501
create a Deployment # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_deployment(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Deployment body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Deployment
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Deployment
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Deployment
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_deployment_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -358,28 +438,44 @@ def create_namespaced_deployment_with_http_info(self, namespace, body, **kwargs)
create a Deployment # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_deployment_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Deployment body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Deployment
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Deployment, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Deployment, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -397,7 +493,10 @@ def create_namespaced_deployment_with_http_info(self, namespace, body, **kwargs)
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -410,12 +509,10 @@ def create_namespaced_deployment_with_http_info(self, namespace, body, **kwargs)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_deployment`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_deployment`") # noqa: E501
collection_formats = {}
@@ -425,16 +522,16 @@ def create_namespaced_deployment_with_http_info(self, namespace, body, **kwargs)
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -449,6 +546,13 @@ def create_namespaced_deployment_with_http_info(self, namespace, body, **kwargs)
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Deployment",
+ 201: "V1Deployment",
+ 202: "V1Deployment",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/deployments', 'POST',
path_params,
@@ -457,13 +561,14 @@ def create_namespaced_deployment_with_http_info(self, namespace, body, **kwargs)
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Deployment', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_namespaced_replica_set(self, namespace, body, **kwargs): # noqa: E501
"""create_namespaced_replica_set # noqa: E501
@@ -471,26 +576,36 @@ def create_namespaced_replica_set(self, namespace, body, **kwargs): # noqa: E50
create a ReplicaSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_replica_set(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ReplicaSet body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ReplicaSet
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ReplicaSet
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ReplicaSet
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_replica_set_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -501,28 +616,44 @@ def create_namespaced_replica_set_with_http_info(self, namespace, body, **kwargs
create a ReplicaSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_replica_set_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ReplicaSet body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ReplicaSet
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ReplicaSet, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ReplicaSet, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -540,7 +671,10 @@ def create_namespaced_replica_set_with_http_info(self, namespace, body, **kwargs
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -553,12 +687,10 @@ def create_namespaced_replica_set_with_http_info(self, namespace, body, **kwargs
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_replica_set`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_replica_set`") # noqa: E501
collection_formats = {}
@@ -568,16 +700,16 @@ def create_namespaced_replica_set_with_http_info(self, namespace, body, **kwargs
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -592,6 +724,13 @@ def create_namespaced_replica_set_with_http_info(self, namespace, body, **kwargs
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ReplicaSet",
+ 201: "V1ReplicaSet",
+ 202: "V1ReplicaSet",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/replicasets', 'POST',
path_params,
@@ -600,13 +739,14 @@ def create_namespaced_replica_set_with_http_info(self, namespace, body, **kwargs
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ReplicaSet', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_namespaced_stateful_set(self, namespace, body, **kwargs): # noqa: E501
"""create_namespaced_stateful_set # noqa: E501
@@ -614,26 +754,36 @@ def create_namespaced_stateful_set(self, namespace, body, **kwargs): # noqa: E5
create a StatefulSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_stateful_set(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1StatefulSet body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1StatefulSet
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1StatefulSet
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1StatefulSet
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_stateful_set_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -644,28 +794,44 @@ def create_namespaced_stateful_set_with_http_info(self, namespace, body, **kwarg
create a StatefulSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_stateful_set_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1StatefulSet body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1StatefulSet
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1StatefulSet, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1StatefulSet, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -683,7 +849,10 @@ def create_namespaced_stateful_set_with_http_info(self, namespace, body, **kwarg
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -696,12 +865,10 @@ def create_namespaced_stateful_set_with_http_info(self, namespace, body, **kwarg
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_stateful_set`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_stateful_set`") # noqa: E501
collection_formats = {}
@@ -711,16 +878,16 @@ def create_namespaced_stateful_set_with_http_info(self, namespace, body, **kwarg
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -735,6 +902,13 @@ def create_namespaced_stateful_set_with_http_info(self, namespace, body, **kwarg
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1StatefulSet",
+ 201: "V1StatefulSet",
+ 202: "V1StatefulSet",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/statefulsets', 'POST',
path_params,
@@ -743,13 +917,14 @@ def create_namespaced_stateful_set_with_http_info(self, namespace, body, **kwarg
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1StatefulSet', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_namespaced_controller_revision(self, namespace, **kwargs): # noqa: E501
"""delete_collection_namespaced_controller_revision # noqa: E501
@@ -757,36 +932,56 @@ def delete_collection_namespaced_controller_revision(self, namespace, **kwargs):
delete collection of ControllerRevision # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_controller_revision(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_namespaced_controller_revision_with_http_info(namespace, **kwargs) # noqa: E501
@@ -797,38 +992,64 @@ def delete_collection_namespaced_controller_revision_with_http_info(self, namesp
delete collection of ControllerRevision # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_controller_revision_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -856,7 +1077,10 @@ def delete_collection_namespaced_controller_revision_with_http_info(self, namesp
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -869,8 +1093,7 @@ def delete_collection_namespaced_controller_revision_with_http_info(self, namesp
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_controller_revision`") # noqa: E501
collection_formats = {}
@@ -880,36 +1103,36 @@ def delete_collection_namespaced_controller_revision_with_http_info(self, namesp
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -924,6 +1147,11 @@ def delete_collection_namespaced_controller_revision_with_http_info(self, namesp
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/controllerrevisions', 'DELETE',
path_params,
@@ -932,13 +1160,14 @@ def delete_collection_namespaced_controller_revision_with_http_info(self, namesp
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_namespaced_daemon_set(self, namespace, **kwargs): # noqa: E501
"""delete_collection_namespaced_daemon_set # noqa: E501
@@ -946,36 +1175,56 @@ def delete_collection_namespaced_daemon_set(self, namespace, **kwargs): # noqa:
delete collection of DaemonSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_daemon_set(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_namespaced_daemon_set_with_http_info(namespace, **kwargs) # noqa: E501
@@ -986,38 +1235,64 @@ def delete_collection_namespaced_daemon_set_with_http_info(self, namespace, **kw
delete collection of DaemonSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_daemon_set_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1045,7 +1320,10 @@ def delete_collection_namespaced_daemon_set_with_http_info(self, namespace, **kw
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1058,8 +1336,7 @@ def delete_collection_namespaced_daemon_set_with_http_info(self, namespace, **kw
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_daemon_set`") # noqa: E501
collection_formats = {}
@@ -1069,36 +1346,36 @@ def delete_collection_namespaced_daemon_set_with_http_info(self, namespace, **kw
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1113,6 +1390,11 @@ def delete_collection_namespaced_daemon_set_with_http_info(self, namespace, **kw
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/daemonsets', 'DELETE',
path_params,
@@ -1121,13 +1403,14 @@ def delete_collection_namespaced_daemon_set_with_http_info(self, namespace, **kw
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_namespaced_deployment(self, namespace, **kwargs): # noqa: E501
"""delete_collection_namespaced_deployment # noqa: E501
@@ -1135,36 +1418,56 @@ def delete_collection_namespaced_deployment(self, namespace, **kwargs): # noqa:
delete collection of Deployment # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_deployment(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_namespaced_deployment_with_http_info(namespace, **kwargs) # noqa: E501
@@ -1175,38 +1478,64 @@ def delete_collection_namespaced_deployment_with_http_info(self, namespace, **kw
delete collection of Deployment # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_deployment_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1234,7 +1563,10 @@ def delete_collection_namespaced_deployment_with_http_info(self, namespace, **kw
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1247,8 +1579,7 @@ def delete_collection_namespaced_deployment_with_http_info(self, namespace, **kw
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_deployment`") # noqa: E501
collection_formats = {}
@@ -1258,36 +1589,36 @@ def delete_collection_namespaced_deployment_with_http_info(self, namespace, **kw
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1302,6 +1633,11 @@ def delete_collection_namespaced_deployment_with_http_info(self, namespace, **kw
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/deployments', 'DELETE',
path_params,
@@ -1310,13 +1646,14 @@ def delete_collection_namespaced_deployment_with_http_info(self, namespace, **kw
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_namespaced_replica_set(self, namespace, **kwargs): # noqa: E501
"""delete_collection_namespaced_replica_set # noqa: E501
@@ -1324,36 +1661,56 @@ def delete_collection_namespaced_replica_set(self, namespace, **kwargs): # noqa
delete collection of ReplicaSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_replica_set(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_namespaced_replica_set_with_http_info(namespace, **kwargs) # noqa: E501
@@ -1364,38 +1721,64 @@ def delete_collection_namespaced_replica_set_with_http_info(self, namespace, **k
delete collection of ReplicaSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_replica_set_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1423,7 +1806,10 @@ def delete_collection_namespaced_replica_set_with_http_info(self, namespace, **k
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1436,8 +1822,7 @@ def delete_collection_namespaced_replica_set_with_http_info(self, namespace, **k
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_replica_set`") # noqa: E501
collection_formats = {}
@@ -1447,36 +1832,36 @@ def delete_collection_namespaced_replica_set_with_http_info(self, namespace, **k
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1491,6 +1876,11 @@ def delete_collection_namespaced_replica_set_with_http_info(self, namespace, **k
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/replicasets', 'DELETE',
path_params,
@@ -1499,13 +1889,14 @@ def delete_collection_namespaced_replica_set_with_http_info(self, namespace, **k
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_namespaced_stateful_set(self, namespace, **kwargs): # noqa: E501
"""delete_collection_namespaced_stateful_set # noqa: E501
@@ -1513,36 +1904,56 @@ def delete_collection_namespaced_stateful_set(self, namespace, **kwargs): # noq
delete collection of StatefulSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_stateful_set(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_namespaced_stateful_set_with_http_info(namespace, **kwargs) # noqa: E501
@@ -1553,38 +1964,64 @@ def delete_collection_namespaced_stateful_set_with_http_info(self, namespace, **
delete collection of StatefulSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_stateful_set_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1612,7 +2049,10 @@ def delete_collection_namespaced_stateful_set_with_http_info(self, namespace, **
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1625,8 +2065,7 @@ def delete_collection_namespaced_stateful_set_with_http_info(self, namespace, **
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_stateful_set`") # noqa: E501
collection_formats = {}
@@ -1636,36 +2075,36 @@ def delete_collection_namespaced_stateful_set_with_http_info(self, namespace, **
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1680,6 +2119,11 @@ def delete_collection_namespaced_stateful_set_with_http_info(self, namespace, **
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/statefulsets', 'DELETE',
path_params,
@@ -1688,13 +2132,14 @@ def delete_collection_namespaced_stateful_set_with_http_info(self, namespace, **
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_namespaced_controller_revision(self, name, namespace, **kwargs): # noqa: E501
"""delete_namespaced_controller_revision # noqa: E501
@@ -1702,29 +2147,42 @@ def delete_namespaced_controller_revision(self, name, namespace, **kwargs): # n
delete a ControllerRevision # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_controller_revision(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ControllerRevision (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the ControllerRevision (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_namespaced_controller_revision_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -1735,31 +2193,50 @@ def delete_namespaced_controller_revision_with_http_info(self, name, namespace,
delete a ControllerRevision # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_controller_revision_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ControllerRevision (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the ControllerRevision (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1780,7 +2257,10 @@ def delete_namespaced_controller_revision_with_http_info(self, name, namespace,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1793,12 +2273,10 @@ def delete_namespaced_controller_revision_with_http_info(self, name, namespace,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_controller_revision`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_controller_revision`") # noqa: E501
collection_formats = {}
@@ -1810,20 +2288,20 @@ def delete_namespaced_controller_revision_with_http_info(self, name, namespace,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1838,6 +2316,12 @@ def delete_namespaced_controller_revision_with_http_info(self, name, namespace,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/controllerrevisions/{name}', 'DELETE',
path_params,
@@ -1846,13 +2330,14 @@ def delete_namespaced_controller_revision_with_http_info(self, name, namespace,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_namespaced_daemon_set(self, name, namespace, **kwargs): # noqa: E501
"""delete_namespaced_daemon_set # noqa: E501
@@ -1860,29 +2345,42 @@ def delete_namespaced_daemon_set(self, name, namespace, **kwargs): # noqa: E501
delete a DaemonSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_daemon_set(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the DaemonSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the DaemonSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_namespaced_daemon_set_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -1893,31 +2391,50 @@ def delete_namespaced_daemon_set_with_http_info(self, name, namespace, **kwargs)
delete a DaemonSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_daemon_set_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the DaemonSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the DaemonSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1938,7 +2455,10 @@ def delete_namespaced_daemon_set_with_http_info(self, name, namespace, **kwargs)
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1951,12 +2471,10 @@ def delete_namespaced_daemon_set_with_http_info(self, name, namespace, **kwargs)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_daemon_set`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_daemon_set`") # noqa: E501
collection_formats = {}
@@ -1968,20 +2486,20 @@ def delete_namespaced_daemon_set_with_http_info(self, name, namespace, **kwargs)
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1996,6 +2514,12 @@ def delete_namespaced_daemon_set_with_http_info(self, name, namespace, **kwargs)
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/daemonsets/{name}', 'DELETE',
path_params,
@@ -2004,13 +2528,14 @@ def delete_namespaced_daemon_set_with_http_info(self, name, namespace, **kwargs)
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_namespaced_deployment(self, name, namespace, **kwargs): # noqa: E501
"""delete_namespaced_deployment # noqa: E501
@@ -2018,29 +2543,42 @@ def delete_namespaced_deployment(self, name, namespace, **kwargs): # noqa: E501
delete a Deployment # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_deployment(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Deployment (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the Deployment (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_namespaced_deployment_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -2051,31 +2589,50 @@ def delete_namespaced_deployment_with_http_info(self, name, namespace, **kwargs)
delete a Deployment # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_deployment_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Deployment (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the Deployment (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2096,7 +2653,10 @@ def delete_namespaced_deployment_with_http_info(self, name, namespace, **kwargs)
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2109,12 +2669,10 @@ def delete_namespaced_deployment_with_http_info(self, name, namespace, **kwargs)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_deployment`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_deployment`") # noqa: E501
collection_formats = {}
@@ -2126,20 +2684,20 @@ def delete_namespaced_deployment_with_http_info(self, name, namespace, **kwargs)
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2154,6 +2712,12 @@ def delete_namespaced_deployment_with_http_info(self, name, namespace, **kwargs)
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/deployments/{name}', 'DELETE',
path_params,
@@ -2162,13 +2726,14 @@ def delete_namespaced_deployment_with_http_info(self, name, namespace, **kwargs)
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_namespaced_replica_set(self, name, namespace, **kwargs): # noqa: E501
"""delete_namespaced_replica_set # noqa: E501
@@ -2176,29 +2741,42 @@ def delete_namespaced_replica_set(self, name, namespace, **kwargs): # noqa: E50
delete a ReplicaSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_replica_set(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ReplicaSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the ReplicaSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_namespaced_replica_set_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -2209,31 +2787,50 @@ def delete_namespaced_replica_set_with_http_info(self, name, namespace, **kwargs
delete a ReplicaSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_replica_set_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ReplicaSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the ReplicaSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2254,7 +2851,10 @@ def delete_namespaced_replica_set_with_http_info(self, name, namespace, **kwargs
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2267,12 +2867,10 @@ def delete_namespaced_replica_set_with_http_info(self, name, namespace, **kwargs
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_replica_set`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_replica_set`") # noqa: E501
collection_formats = {}
@@ -2284,20 +2882,20 @@ def delete_namespaced_replica_set_with_http_info(self, name, namespace, **kwargs
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2312,6 +2910,12 @@ def delete_namespaced_replica_set_with_http_info(self, name, namespace, **kwargs
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/replicasets/{name}', 'DELETE',
path_params,
@@ -2320,13 +2924,14 @@ def delete_namespaced_replica_set_with_http_info(self, name, namespace, **kwargs
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_namespaced_stateful_set(self, name, namespace, **kwargs): # noqa: E501
"""delete_namespaced_stateful_set # noqa: E501
@@ -2334,29 +2939,42 @@ def delete_namespaced_stateful_set(self, name, namespace, **kwargs): # noqa: E5
delete a StatefulSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_stateful_set(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the StatefulSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the StatefulSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_namespaced_stateful_set_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -2367,31 +2985,50 @@ def delete_namespaced_stateful_set_with_http_info(self, name, namespace, **kwarg
delete a StatefulSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_stateful_set_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the StatefulSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the StatefulSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2412,7 +3049,10 @@ def delete_namespaced_stateful_set_with_http_info(self, name, namespace, **kwarg
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2425,12 +3065,10 @@ def delete_namespaced_stateful_set_with_http_info(self, name, namespace, **kwarg
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_stateful_set`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_stateful_set`") # noqa: E501
collection_formats = {}
@@ -2442,20 +3080,20 @@ def delete_namespaced_stateful_set_with_http_info(self, name, namespace, **kwarg
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2470,6 +3108,12 @@ def delete_namespaced_stateful_set_with_http_info(self, name, namespace, **kwarg
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/statefulsets/{name}', 'DELETE',
path_params,
@@ -2478,13 +3122,14 @@ def delete_namespaced_stateful_set_with_http_info(self, name, namespace, **kwarg
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def get_api_resources(self, **kwargs): # noqa: E501
"""get_api_resources # noqa: E501
@@ -2492,20 +3137,24 @@ def get_api_resources(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIResourceList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIResourceList
"""
kwargs['_return_http_data_only'] = True
return self.get_api_resources_with_http_info(**kwargs) # noqa: E501
@@ -2516,22 +3165,32 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2543,7 +3202,10 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2562,7 +3224,7 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2575,6 +3237,11 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIResourceList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/', 'GET',
path_params,
@@ -2583,13 +3250,14 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIResourceList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_controller_revision_for_all_namespaces(self, **kwargs): # noqa: E501
"""list_controller_revision_for_all_namespaces # noqa: E501
@@ -2597,31 +3265,46 @@ def list_controller_revision_for_all_namespaces(self, **kwargs): # noqa: E501
list or watch objects of kind ControllerRevision # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_controller_revision_for_all_namespaces(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ControllerRevisionList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ControllerRevisionList
"""
kwargs['_return_http_data_only'] = True
return self.list_controller_revision_for_all_namespaces_with_http_info(**kwargs) # noqa: E501
@@ -2632,33 +3315,54 @@ def list_controller_revision_for_all_namespaces_with_http_info(self, **kwargs):
list or watch objects of kind ControllerRevision # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_controller_revision_for_all_namespaces_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ControllerRevisionList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ControllerRevisionList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2681,7 +3385,10 @@ def list_controller_revision_for_all_namespaces_with_http_info(self, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2699,30 +3406,30 @@ def list_controller_revision_for_all_namespaces_with_http_info(self, **kwargs):
path_params = {}
query_params = []
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2735,6 +3442,11 @@ def list_controller_revision_for_all_namespaces_with_http_info(self, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ControllerRevisionList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/controllerrevisions', 'GET',
path_params,
@@ -2743,13 +3455,14 @@ def list_controller_revision_for_all_namespaces_with_http_info(self, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ControllerRevisionList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_daemon_set_for_all_namespaces(self, **kwargs): # noqa: E501
"""list_daemon_set_for_all_namespaces # noqa: E501
@@ -2757,31 +3470,46 @@ def list_daemon_set_for_all_namespaces(self, **kwargs): # noqa: E501
list or watch objects of kind DaemonSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_daemon_set_for_all_namespaces(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1DaemonSetList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1DaemonSetList
"""
kwargs['_return_http_data_only'] = True
return self.list_daemon_set_for_all_namespaces_with_http_info(**kwargs) # noqa: E501
@@ -2792,33 +3520,54 @@ def list_daemon_set_for_all_namespaces_with_http_info(self, **kwargs): # noqa:
list or watch objects of kind DaemonSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_daemon_set_for_all_namespaces_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1DaemonSetList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1DaemonSetList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2841,7 +3590,10 @@ def list_daemon_set_for_all_namespaces_with_http_info(self, **kwargs): # noqa:
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2859,30 +3611,30 @@ def list_daemon_set_for_all_namespaces_with_http_info(self, **kwargs): # noqa:
path_params = {}
query_params = []
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2895,6 +3647,11 @@ def list_daemon_set_for_all_namespaces_with_http_info(self, **kwargs): # noqa:
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1DaemonSetList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/daemonsets', 'GET',
path_params,
@@ -2903,13 +3660,14 @@ def list_daemon_set_for_all_namespaces_with_http_info(self, **kwargs): # noqa:
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1DaemonSetList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_deployment_for_all_namespaces(self, **kwargs): # noqa: E501
"""list_deployment_for_all_namespaces # noqa: E501
@@ -2917,31 +3675,46 @@ def list_deployment_for_all_namespaces(self, **kwargs): # noqa: E501
list or watch objects of kind Deployment # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_deployment_for_all_namespaces(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1DeploymentList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1DeploymentList
"""
kwargs['_return_http_data_only'] = True
return self.list_deployment_for_all_namespaces_with_http_info(**kwargs) # noqa: E501
@@ -2952,33 +3725,54 @@ def list_deployment_for_all_namespaces_with_http_info(self, **kwargs): # noqa:
list or watch objects of kind Deployment # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_deployment_for_all_namespaces_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1DeploymentList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1DeploymentList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3001,7 +3795,10 @@ def list_deployment_for_all_namespaces_with_http_info(self, **kwargs): # noqa:
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3019,30 +3816,30 @@ def list_deployment_for_all_namespaces_with_http_info(self, **kwargs): # noqa:
path_params = {}
query_params = []
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3055,6 +3852,11 @@ def list_deployment_for_all_namespaces_with_http_info(self, **kwargs): # noqa:
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1DeploymentList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/deployments', 'GET',
path_params,
@@ -3063,13 +3865,14 @@ def list_deployment_for_all_namespaces_with_http_info(self, **kwargs): # noqa:
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1DeploymentList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_namespaced_controller_revision(self, namespace, **kwargs): # noqa: E501
"""list_namespaced_controller_revision # noqa: E501
@@ -3077,32 +3880,48 @@ def list_namespaced_controller_revision(self, namespace, **kwargs): # noqa: E50
list or watch objects of kind ControllerRevision # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_controller_revision(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ControllerRevisionList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ControllerRevisionList
"""
kwargs['_return_http_data_only'] = True
return self.list_namespaced_controller_revision_with_http_info(namespace, **kwargs) # noqa: E501
@@ -3113,34 +3932,56 @@ def list_namespaced_controller_revision_with_http_info(self, namespace, **kwargs
list or watch objects of kind ControllerRevision # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_controller_revision_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ControllerRevisionList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ControllerRevisionList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3164,7 +4005,10 @@ def list_namespaced_controller_revision_with_http_info(self, namespace, **kwargs
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3177,8 +4021,7 @@ def list_namespaced_controller_revision_with_http_info(self, namespace, **kwargs
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_controller_revision`") # noqa: E501
collection_formats = {}
@@ -3188,30 +4031,30 @@ def list_namespaced_controller_revision_with_http_info(self, namespace, **kwargs
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3224,6 +4067,11 @@ def list_namespaced_controller_revision_with_http_info(self, namespace, **kwargs
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ControllerRevisionList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/controllerrevisions', 'GET',
path_params,
@@ -3232,13 +4080,14 @@ def list_namespaced_controller_revision_with_http_info(self, namespace, **kwargs
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ControllerRevisionList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_namespaced_daemon_set(self, namespace, **kwargs): # noqa: E501
"""list_namespaced_daemon_set # noqa: E501
@@ -3246,32 +4095,48 @@ def list_namespaced_daemon_set(self, namespace, **kwargs): # noqa: E501
list or watch objects of kind DaemonSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_daemon_set(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1DaemonSetList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1DaemonSetList
"""
kwargs['_return_http_data_only'] = True
return self.list_namespaced_daemon_set_with_http_info(namespace, **kwargs) # noqa: E501
@@ -3282,34 +4147,56 @@ def list_namespaced_daemon_set_with_http_info(self, namespace, **kwargs): # noq
list or watch objects of kind DaemonSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_daemon_set_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1DaemonSetList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1DaemonSetList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3333,7 +4220,10 @@ def list_namespaced_daemon_set_with_http_info(self, namespace, **kwargs): # noq
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3346,8 +4236,7 @@ def list_namespaced_daemon_set_with_http_info(self, namespace, **kwargs): # noq
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_daemon_set`") # noqa: E501
collection_formats = {}
@@ -3357,30 +4246,30 @@ def list_namespaced_daemon_set_with_http_info(self, namespace, **kwargs): # noq
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3393,6 +4282,11 @@ def list_namespaced_daemon_set_with_http_info(self, namespace, **kwargs): # noq
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1DaemonSetList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/daemonsets', 'GET',
path_params,
@@ -3401,13 +4295,14 @@ def list_namespaced_daemon_set_with_http_info(self, namespace, **kwargs): # noq
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1DaemonSetList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_namespaced_deployment(self, namespace, **kwargs): # noqa: E501
"""list_namespaced_deployment # noqa: E501
@@ -3415,32 +4310,48 @@ def list_namespaced_deployment(self, namespace, **kwargs): # noqa: E501
list or watch objects of kind Deployment # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_deployment(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1DeploymentList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1DeploymentList
"""
kwargs['_return_http_data_only'] = True
return self.list_namespaced_deployment_with_http_info(namespace, **kwargs) # noqa: E501
@@ -3451,34 +4362,56 @@ def list_namespaced_deployment_with_http_info(self, namespace, **kwargs): # noq
list or watch objects of kind Deployment # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_deployment_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1DeploymentList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1DeploymentList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3502,7 +4435,10 @@ def list_namespaced_deployment_with_http_info(self, namespace, **kwargs): # noq
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3515,8 +4451,7 @@ def list_namespaced_deployment_with_http_info(self, namespace, **kwargs): # noq
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_deployment`") # noqa: E501
collection_formats = {}
@@ -3526,30 +4461,30 @@ def list_namespaced_deployment_with_http_info(self, namespace, **kwargs): # noq
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3562,6 +4497,11 @@ def list_namespaced_deployment_with_http_info(self, namespace, **kwargs): # noq
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1DeploymentList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/deployments', 'GET',
path_params,
@@ -3570,13 +4510,14 @@ def list_namespaced_deployment_with_http_info(self, namespace, **kwargs): # noq
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1DeploymentList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_namespaced_replica_set(self, namespace, **kwargs): # noqa: E501
"""list_namespaced_replica_set # noqa: E501
@@ -3584,32 +4525,48 @@ def list_namespaced_replica_set(self, namespace, **kwargs): # noqa: E501
list or watch objects of kind ReplicaSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_replica_set(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ReplicaSetList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ReplicaSetList
"""
kwargs['_return_http_data_only'] = True
return self.list_namespaced_replica_set_with_http_info(namespace, **kwargs) # noqa: E501
@@ -3620,34 +4577,56 @@ def list_namespaced_replica_set_with_http_info(self, namespace, **kwargs): # no
list or watch objects of kind ReplicaSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_replica_set_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ReplicaSetList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ReplicaSetList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3671,7 +4650,10 @@ def list_namespaced_replica_set_with_http_info(self, namespace, **kwargs): # no
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3684,8 +4666,7 @@ def list_namespaced_replica_set_with_http_info(self, namespace, **kwargs): # no
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_replica_set`") # noqa: E501
collection_formats = {}
@@ -3695,30 +4676,30 @@ def list_namespaced_replica_set_with_http_info(self, namespace, **kwargs): # no
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3731,6 +4712,11 @@ def list_namespaced_replica_set_with_http_info(self, namespace, **kwargs): # no
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ReplicaSetList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/replicasets', 'GET',
path_params,
@@ -3739,13 +4725,14 @@ def list_namespaced_replica_set_with_http_info(self, namespace, **kwargs): # no
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ReplicaSetList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_namespaced_stateful_set(self, namespace, **kwargs): # noqa: E501
"""list_namespaced_stateful_set # noqa: E501
@@ -3753,32 +4740,48 @@ def list_namespaced_stateful_set(self, namespace, **kwargs): # noqa: E501
list or watch objects of kind StatefulSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_stateful_set(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1StatefulSetList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1StatefulSetList
"""
kwargs['_return_http_data_only'] = True
return self.list_namespaced_stateful_set_with_http_info(namespace, **kwargs) # noqa: E501
@@ -3789,34 +4792,56 @@ def list_namespaced_stateful_set_with_http_info(self, namespace, **kwargs): # n
list or watch objects of kind StatefulSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_stateful_set_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1StatefulSetList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1StatefulSetList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3840,7 +4865,10 @@ def list_namespaced_stateful_set_with_http_info(self, namespace, **kwargs): # n
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3853,8 +4881,7 @@ def list_namespaced_stateful_set_with_http_info(self, namespace, **kwargs): # n
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_stateful_set`") # noqa: E501
collection_formats = {}
@@ -3864,30 +4891,30 @@ def list_namespaced_stateful_set_with_http_info(self, namespace, **kwargs): # n
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3900,6 +4927,11 @@ def list_namespaced_stateful_set_with_http_info(self, namespace, **kwargs): # n
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1StatefulSetList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/statefulsets', 'GET',
path_params,
@@ -3908,13 +4940,14 @@ def list_namespaced_stateful_set_with_http_info(self, namespace, **kwargs): # n
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1StatefulSetList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_replica_set_for_all_namespaces(self, **kwargs): # noqa: E501
"""list_replica_set_for_all_namespaces # noqa: E501
@@ -3922,31 +4955,46 @@ def list_replica_set_for_all_namespaces(self, **kwargs): # noqa: E501
list or watch objects of kind ReplicaSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_replica_set_for_all_namespaces(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ReplicaSetList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ReplicaSetList
"""
kwargs['_return_http_data_only'] = True
return self.list_replica_set_for_all_namespaces_with_http_info(**kwargs) # noqa: E501
@@ -3957,33 +5005,54 @@ def list_replica_set_for_all_namespaces_with_http_info(self, **kwargs): # noqa:
list or watch objects of kind ReplicaSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_replica_set_for_all_namespaces_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ReplicaSetList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ReplicaSetList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -4006,7 +5075,10 @@ def list_replica_set_for_all_namespaces_with_http_info(self, **kwargs): # noqa:
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -4024,30 +5096,30 @@ def list_replica_set_for_all_namespaces_with_http_info(self, **kwargs): # noqa:
path_params = {}
query_params = []
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -4060,6 +5132,11 @@ def list_replica_set_for_all_namespaces_with_http_info(self, **kwargs): # noqa:
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ReplicaSetList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/replicasets', 'GET',
path_params,
@@ -4068,13 +5145,14 @@ def list_replica_set_for_all_namespaces_with_http_info(self, **kwargs): # noqa:
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ReplicaSetList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_stateful_set_for_all_namespaces(self, **kwargs): # noqa: E501
"""list_stateful_set_for_all_namespaces # noqa: E501
@@ -4082,31 +5160,46 @@ def list_stateful_set_for_all_namespaces(self, **kwargs): # noqa: E501
list or watch objects of kind StatefulSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_stateful_set_for_all_namespaces(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1StatefulSetList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1StatefulSetList
"""
kwargs['_return_http_data_only'] = True
return self.list_stateful_set_for_all_namespaces_with_http_info(**kwargs) # noqa: E501
@@ -4117,33 +5210,54 @@ def list_stateful_set_for_all_namespaces_with_http_info(self, **kwargs): # noqa
list or watch objects of kind StatefulSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_stateful_set_for_all_namespaces_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1StatefulSetList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1StatefulSetList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -4166,7 +5280,10 @@ def list_stateful_set_for_all_namespaces_with_http_info(self, **kwargs): # noqa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -4184,30 +5301,30 @@ def list_stateful_set_for_all_namespaces_with_http_info(self, **kwargs): # noqa
path_params = {}
query_params = []
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -4220,6 +5337,11 @@ def list_stateful_set_for_all_namespaces_with_http_info(self, **kwargs): # noqa
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1StatefulSetList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/statefulsets', 'GET',
path_params,
@@ -4228,13 +5350,14 @@ def list_stateful_set_for_all_namespaces_with_http_info(self, **kwargs): # noqa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1StatefulSetList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_controller_revision(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_controller_revision # noqa: E501
@@ -4242,28 +5365,40 @@ def patch_namespaced_controller_revision(self, name, namespace, body, **kwargs):
partially update the specified ControllerRevision # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_controller_revision(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ControllerRevision (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ControllerRevision (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ControllerRevision
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ControllerRevision
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_controller_revision_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -4274,30 +5409,48 @@ def patch_namespaced_controller_revision_with_http_info(self, name, namespace, b
partially update the specified ControllerRevision # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_controller_revision_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ControllerRevision (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ControllerRevision (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ControllerRevision, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ControllerRevision, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -4317,7 +5470,10 @@ def patch_namespaced_controller_revision_with_http_info(self, name, namespace, b
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -4330,16 +5486,13 @@ def patch_namespaced_controller_revision_with_http_info(self, name, namespace, b
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_controller_revision`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_controller_revision`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_controller_revision`") # noqa: E501
collection_formats = {}
@@ -4351,18 +5504,18 @@ def patch_namespaced_controller_revision_with_http_info(self, name, namespace, b
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -4375,12 +5528,22 @@ def patch_namespaced_controller_revision_with_http_info(self, name, namespace, b
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ControllerRevision",
+ 201: "V1ControllerRevision",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/controllerrevisions/{name}', 'PATCH',
path_params,
@@ -4389,13 +5552,14 @@ def patch_namespaced_controller_revision_with_http_info(self, name, namespace, b
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ControllerRevision', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_daemon_set(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_daemon_set # noqa: E501
@@ -4403,28 +5567,40 @@ def patch_namespaced_daemon_set(self, name, namespace, body, **kwargs): # noqa:
partially update the specified DaemonSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_daemon_set(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the DaemonSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the DaemonSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1DaemonSet
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1DaemonSet
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_daemon_set_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -4435,30 +5611,48 @@ def patch_namespaced_daemon_set_with_http_info(self, name, namespace, body, **kw
partially update the specified DaemonSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_daemon_set_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the DaemonSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the DaemonSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1DaemonSet, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1DaemonSet, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -4478,7 +5672,10 @@ def patch_namespaced_daemon_set_with_http_info(self, name, namespace, body, **kw
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -4491,16 +5688,13 @@ def patch_namespaced_daemon_set_with_http_info(self, name, namespace, body, **kw
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_daemon_set`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_daemon_set`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_daemon_set`") # noqa: E501
collection_formats = {}
@@ -4512,18 +5706,18 @@ def patch_namespaced_daemon_set_with_http_info(self, name, namespace, body, **kw
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -4536,12 +5730,22 @@ def patch_namespaced_daemon_set_with_http_info(self, name, namespace, body, **kw
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1DaemonSet",
+ 201: "V1DaemonSet",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/daemonsets/{name}', 'PATCH',
path_params,
@@ -4550,13 +5754,14 @@ def patch_namespaced_daemon_set_with_http_info(self, name, namespace, body, **kw
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1DaemonSet', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_daemon_set_status(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_daemon_set_status # noqa: E501
@@ -4564,28 +5769,40 @@ def patch_namespaced_daemon_set_status(self, name, namespace, body, **kwargs):
partially update status of the specified DaemonSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_daemon_set_status(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the DaemonSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the DaemonSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1DaemonSet
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1DaemonSet
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_daemon_set_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -4596,30 +5813,48 @@ def patch_namespaced_daemon_set_status_with_http_info(self, name, namespace, bod
partially update status of the specified DaemonSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_daemon_set_status_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the DaemonSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the DaemonSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1DaemonSet, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1DaemonSet, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -4639,7 +5874,10 @@ def patch_namespaced_daemon_set_status_with_http_info(self, name, namespace, bod
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -4652,16 +5890,13 @@ def patch_namespaced_daemon_set_status_with_http_info(self, name, namespace, bod
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_daemon_set_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_daemon_set_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_daemon_set_status`") # noqa: E501
collection_formats = {}
@@ -4673,18 +5908,18 @@ def patch_namespaced_daemon_set_status_with_http_info(self, name, namespace, bod
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -4697,12 +5932,22 @@ def patch_namespaced_daemon_set_status_with_http_info(self, name, namespace, bod
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1DaemonSet",
+ 201: "V1DaemonSet",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/daemonsets/{name}/status', 'PATCH',
path_params,
@@ -4711,13 +5956,14 @@ def patch_namespaced_daemon_set_status_with_http_info(self, name, namespace, bod
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1DaemonSet', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_deployment(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_deployment # noqa: E501
@@ -4725,28 +5971,40 @@ def patch_namespaced_deployment(self, name, namespace, body, **kwargs): # noqa:
partially update the specified Deployment # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_deployment(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Deployment (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Deployment (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Deployment
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Deployment
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_deployment_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -4757,30 +6015,48 @@ def patch_namespaced_deployment_with_http_info(self, name, namespace, body, **kw
partially update the specified Deployment # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_deployment_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Deployment (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Deployment (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Deployment, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Deployment, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -4800,7 +6076,10 @@ def patch_namespaced_deployment_with_http_info(self, name, namespace, body, **kw
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -4813,16 +6092,13 @@ def patch_namespaced_deployment_with_http_info(self, name, namespace, body, **kw
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_deployment`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_deployment`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_deployment`") # noqa: E501
collection_formats = {}
@@ -4834,18 +6110,18 @@ def patch_namespaced_deployment_with_http_info(self, name, namespace, body, **kw
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -4858,12 +6134,22 @@ def patch_namespaced_deployment_with_http_info(self, name, namespace, body, **kw
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Deployment",
+ 201: "V1Deployment",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/deployments/{name}', 'PATCH',
path_params,
@@ -4872,13 +6158,14 @@ def patch_namespaced_deployment_with_http_info(self, name, namespace, body, **kw
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Deployment', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_deployment_scale(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_deployment_scale # noqa: E501
@@ -4886,28 +6173,40 @@ def patch_namespaced_deployment_scale(self, name, namespace, body, **kwargs): #
partially update scale of the specified Deployment # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_deployment_scale(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Scale (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Scale (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Scale
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Scale
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_deployment_scale_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -4918,30 +6217,48 @@ def patch_namespaced_deployment_scale_with_http_info(self, name, namespace, body
partially update scale of the specified Deployment # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_deployment_scale_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Scale (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Scale (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Scale, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Scale, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -4961,7 +6278,10 @@ def patch_namespaced_deployment_scale_with_http_info(self, name, namespace, body
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -4974,16 +6294,13 @@ def patch_namespaced_deployment_scale_with_http_info(self, name, namespace, body
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_deployment_scale`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_deployment_scale`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_deployment_scale`") # noqa: E501
collection_formats = {}
@@ -4995,18 +6312,18 @@ def patch_namespaced_deployment_scale_with_http_info(self, name, namespace, body
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -5019,12 +6336,22 @@ def patch_namespaced_deployment_scale_with_http_info(self, name, namespace, body
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Scale",
+ 201: "V1Scale",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/deployments/{name}/scale', 'PATCH',
path_params,
@@ -5033,13 +6360,14 @@ def patch_namespaced_deployment_scale_with_http_info(self, name, namespace, body
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Scale', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_deployment_status(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_deployment_status # noqa: E501
@@ -5047,28 +6375,40 @@ def patch_namespaced_deployment_status(self, name, namespace, body, **kwargs):
partially update status of the specified Deployment # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_deployment_status(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Deployment (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Deployment (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Deployment
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Deployment
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_deployment_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -5079,30 +6419,48 @@ def patch_namespaced_deployment_status_with_http_info(self, name, namespace, bod
partially update status of the specified Deployment # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_deployment_status_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Deployment (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Deployment (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Deployment, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Deployment, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -5122,7 +6480,10 @@ def patch_namespaced_deployment_status_with_http_info(self, name, namespace, bod
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -5135,16 +6496,13 @@ def patch_namespaced_deployment_status_with_http_info(self, name, namespace, bod
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_deployment_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_deployment_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_deployment_status`") # noqa: E501
collection_formats = {}
@@ -5156,18 +6514,18 @@ def patch_namespaced_deployment_status_with_http_info(self, name, namespace, bod
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -5180,12 +6538,22 @@ def patch_namespaced_deployment_status_with_http_info(self, name, namespace, bod
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Deployment",
+ 201: "V1Deployment",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/deployments/{name}/status', 'PATCH',
path_params,
@@ -5194,13 +6562,14 @@ def patch_namespaced_deployment_status_with_http_info(self, name, namespace, bod
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Deployment', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_replica_set(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_replica_set # noqa: E501
@@ -5208,28 +6577,40 @@ def patch_namespaced_replica_set(self, name, namespace, body, **kwargs): # noqa
partially update the specified ReplicaSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_replica_set(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ReplicaSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ReplicaSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ReplicaSet
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ReplicaSet
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_replica_set_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -5240,30 +6621,48 @@ def patch_namespaced_replica_set_with_http_info(self, name, namespace, body, **k
partially update the specified ReplicaSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_replica_set_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ReplicaSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ReplicaSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ReplicaSet, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ReplicaSet, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -5283,7 +6682,10 @@ def patch_namespaced_replica_set_with_http_info(self, name, namespace, body, **k
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -5296,16 +6698,13 @@ def patch_namespaced_replica_set_with_http_info(self, name, namespace, body, **k
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_replica_set`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_replica_set`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_replica_set`") # noqa: E501
collection_formats = {}
@@ -5317,18 +6716,18 @@ def patch_namespaced_replica_set_with_http_info(self, name, namespace, body, **k
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -5341,12 +6740,22 @@ def patch_namespaced_replica_set_with_http_info(self, name, namespace, body, **k
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ReplicaSet",
+ 201: "V1ReplicaSet",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/replicasets/{name}', 'PATCH',
path_params,
@@ -5355,13 +6764,14 @@ def patch_namespaced_replica_set_with_http_info(self, name, namespace, body, **k
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ReplicaSet', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_replica_set_scale(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_replica_set_scale # noqa: E501
@@ -5369,28 +6779,40 @@ def patch_namespaced_replica_set_scale(self, name, namespace, body, **kwargs):
partially update scale of the specified ReplicaSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_replica_set_scale(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Scale (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Scale (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Scale
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Scale
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_replica_set_scale_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -5401,30 +6823,48 @@ def patch_namespaced_replica_set_scale_with_http_info(self, name, namespace, bod
partially update scale of the specified ReplicaSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_replica_set_scale_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Scale (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Scale (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Scale, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Scale, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -5444,7 +6884,10 @@ def patch_namespaced_replica_set_scale_with_http_info(self, name, namespace, bod
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -5457,16 +6900,13 @@ def patch_namespaced_replica_set_scale_with_http_info(self, name, namespace, bod
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_replica_set_scale`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_replica_set_scale`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_replica_set_scale`") # noqa: E501
collection_formats = {}
@@ -5478,18 +6918,18 @@ def patch_namespaced_replica_set_scale_with_http_info(self, name, namespace, bod
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -5502,12 +6942,22 @@ def patch_namespaced_replica_set_scale_with_http_info(self, name, namespace, bod
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Scale",
+ 201: "V1Scale",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/replicasets/{name}/scale', 'PATCH',
path_params,
@@ -5516,13 +6966,14 @@ def patch_namespaced_replica_set_scale_with_http_info(self, name, namespace, bod
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Scale', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_replica_set_status(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_replica_set_status # noqa: E501
@@ -5530,28 +6981,40 @@ def patch_namespaced_replica_set_status(self, name, namespace, body, **kwargs):
partially update status of the specified ReplicaSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_replica_set_status(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ReplicaSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ReplicaSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ReplicaSet
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ReplicaSet
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_replica_set_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -5562,30 +7025,48 @@ def patch_namespaced_replica_set_status_with_http_info(self, name, namespace, bo
partially update status of the specified ReplicaSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_replica_set_status_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ReplicaSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ReplicaSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ReplicaSet, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ReplicaSet, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -5605,7 +7086,10 @@ def patch_namespaced_replica_set_status_with_http_info(self, name, namespace, bo
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -5618,16 +7102,13 @@ def patch_namespaced_replica_set_status_with_http_info(self, name, namespace, bo
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_replica_set_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_replica_set_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_replica_set_status`") # noqa: E501
collection_formats = {}
@@ -5639,18 +7120,18 @@ def patch_namespaced_replica_set_status_with_http_info(self, name, namespace, bo
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -5663,12 +7144,22 @@ def patch_namespaced_replica_set_status_with_http_info(self, name, namespace, bo
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ReplicaSet",
+ 201: "V1ReplicaSet",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/replicasets/{name}/status', 'PATCH',
path_params,
@@ -5677,13 +7168,14 @@ def patch_namespaced_replica_set_status_with_http_info(self, name, namespace, bo
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ReplicaSet', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_stateful_set(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_stateful_set # noqa: E501
@@ -5691,28 +7183,40 @@ def patch_namespaced_stateful_set(self, name, namespace, body, **kwargs): # noq
partially update the specified StatefulSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_stateful_set(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the StatefulSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the StatefulSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1StatefulSet
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1StatefulSet
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_stateful_set_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -5723,30 +7227,48 @@ def patch_namespaced_stateful_set_with_http_info(self, name, namespace, body, **
partially update the specified StatefulSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_stateful_set_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the StatefulSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the StatefulSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1StatefulSet, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1StatefulSet, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -5766,7 +7288,10 @@ def patch_namespaced_stateful_set_with_http_info(self, name, namespace, body, **
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -5779,16 +7304,13 @@ def patch_namespaced_stateful_set_with_http_info(self, name, namespace, body, **
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_stateful_set`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_stateful_set`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_stateful_set`") # noqa: E501
collection_formats = {}
@@ -5800,18 +7322,18 @@ def patch_namespaced_stateful_set_with_http_info(self, name, namespace, body, **
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -5824,12 +7346,22 @@ def patch_namespaced_stateful_set_with_http_info(self, name, namespace, body, **
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1StatefulSet",
+ 201: "V1StatefulSet",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/statefulsets/{name}', 'PATCH',
path_params,
@@ -5838,13 +7370,14 @@ def patch_namespaced_stateful_set_with_http_info(self, name, namespace, body, **
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1StatefulSet', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_stateful_set_scale(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_stateful_set_scale # noqa: E501
@@ -5852,28 +7385,40 @@ def patch_namespaced_stateful_set_scale(self, name, namespace, body, **kwargs):
partially update scale of the specified StatefulSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_stateful_set_scale(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Scale (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Scale (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Scale
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Scale
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_stateful_set_scale_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -5884,30 +7429,48 @@ def patch_namespaced_stateful_set_scale_with_http_info(self, name, namespace, bo
partially update scale of the specified StatefulSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_stateful_set_scale_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Scale (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Scale (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Scale, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Scale, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -5927,7 +7490,10 @@ def patch_namespaced_stateful_set_scale_with_http_info(self, name, namespace, bo
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -5940,16 +7506,13 @@ def patch_namespaced_stateful_set_scale_with_http_info(self, name, namespace, bo
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_stateful_set_scale`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_stateful_set_scale`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_stateful_set_scale`") # noqa: E501
collection_formats = {}
@@ -5961,18 +7524,18 @@ def patch_namespaced_stateful_set_scale_with_http_info(self, name, namespace, bo
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -5985,12 +7548,22 @@ def patch_namespaced_stateful_set_scale_with_http_info(self, name, namespace, bo
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Scale",
+ 201: "V1Scale",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/statefulsets/{name}/scale', 'PATCH',
path_params,
@@ -5999,13 +7572,14 @@ def patch_namespaced_stateful_set_scale_with_http_info(self, name, namespace, bo
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Scale', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_stateful_set_status(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_stateful_set_status # noqa: E501
@@ -6013,28 +7587,40 @@ def patch_namespaced_stateful_set_status(self, name, namespace, body, **kwargs):
partially update status of the specified StatefulSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_stateful_set_status(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the StatefulSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the StatefulSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1StatefulSet
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1StatefulSet
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_stateful_set_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -6045,30 +7631,48 @@ def patch_namespaced_stateful_set_status_with_http_info(self, name, namespace, b
partially update status of the specified StatefulSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_stateful_set_status_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the StatefulSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the StatefulSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1StatefulSet, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1StatefulSet, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -6088,7 +7692,10 @@ def patch_namespaced_stateful_set_status_with_http_info(self, name, namespace, b
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -6101,16 +7708,13 @@ def patch_namespaced_stateful_set_status_with_http_info(self, name, namespace, b
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_stateful_set_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_stateful_set_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_stateful_set_status`") # noqa: E501
collection_formats = {}
@@ -6122,18 +7726,18 @@ def patch_namespaced_stateful_set_status_with_http_info(self, name, namespace, b
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -6146,12 +7750,22 @@ def patch_namespaced_stateful_set_status_with_http_info(self, name, namespace, b
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1StatefulSet",
+ 201: "V1StatefulSet",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/statefulsets/{name}/status', 'PATCH',
path_params,
@@ -6160,13 +7774,14 @@ def patch_namespaced_stateful_set_status_with_http_info(self, name, namespace, b
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1StatefulSet', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_controller_revision(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_controller_revision # noqa: E501
@@ -6174,23 +7789,30 @@ def read_namespaced_controller_revision(self, name, namespace, **kwargs): # noq
read the specified ControllerRevision # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_controller_revision(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ControllerRevision (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ControllerRevision (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ControllerRevision
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ControllerRevision
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_controller_revision_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -6201,25 +7823,38 @@ def read_namespaced_controller_revision_with_http_info(self, name, namespace, **
read the specified ControllerRevision # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_controller_revision_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ControllerRevision (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ControllerRevision (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ControllerRevision, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ControllerRevision, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -6234,7 +7869,10 @@ def read_namespaced_controller_revision_with_http_info(self, name, namespace, **
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -6247,12 +7885,10 @@ def read_namespaced_controller_revision_with_http_info(self, name, namespace, **
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_controller_revision`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_controller_revision`") # noqa: E501
collection_formats = {}
@@ -6264,10 +7900,10 @@ def read_namespaced_controller_revision_with_http_info(self, name, namespace, **
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -6280,6 +7916,11 @@ def read_namespaced_controller_revision_with_http_info(self, name, namespace, **
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ControllerRevision",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/controllerrevisions/{name}', 'GET',
path_params,
@@ -6288,13 +7929,14 @@ def read_namespaced_controller_revision_with_http_info(self, name, namespace, **
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ControllerRevision', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_daemon_set(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_daemon_set # noqa: E501
@@ -6302,23 +7944,30 @@ def read_namespaced_daemon_set(self, name, namespace, **kwargs): # noqa: E501
read the specified DaemonSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_daemon_set(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the DaemonSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the DaemonSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1DaemonSet
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1DaemonSet
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_daemon_set_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -6329,25 +7978,38 @@ def read_namespaced_daemon_set_with_http_info(self, name, namespace, **kwargs):
read the specified DaemonSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_daemon_set_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the DaemonSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the DaemonSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1DaemonSet, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1DaemonSet, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -6362,7 +8024,10 @@ def read_namespaced_daemon_set_with_http_info(self, name, namespace, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -6375,12 +8040,10 @@ def read_namespaced_daemon_set_with_http_info(self, name, namespace, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_daemon_set`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_daemon_set`") # noqa: E501
collection_formats = {}
@@ -6392,10 +8055,10 @@ def read_namespaced_daemon_set_with_http_info(self, name, namespace, **kwargs):
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -6408,6 +8071,11 @@ def read_namespaced_daemon_set_with_http_info(self, name, namespace, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1DaemonSet",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/daemonsets/{name}', 'GET',
path_params,
@@ -6416,13 +8084,14 @@ def read_namespaced_daemon_set_with_http_info(self, name, namespace, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1DaemonSet', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_daemon_set_status(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_daemon_set_status # noqa: E501
@@ -6430,23 +8099,30 @@ def read_namespaced_daemon_set_status(self, name, namespace, **kwargs): # noqa:
read status of the specified DaemonSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_daemon_set_status(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the DaemonSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the DaemonSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1DaemonSet
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1DaemonSet
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_daemon_set_status_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -6457,25 +8133,38 @@ def read_namespaced_daemon_set_status_with_http_info(self, name, namespace, **kw
read status of the specified DaemonSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_daemon_set_status_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the DaemonSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the DaemonSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1DaemonSet, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1DaemonSet, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -6490,7 +8179,10 @@ def read_namespaced_daemon_set_status_with_http_info(self, name, namespace, **kw
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -6503,12 +8195,10 @@ def read_namespaced_daemon_set_status_with_http_info(self, name, namespace, **kw
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_daemon_set_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_daemon_set_status`") # noqa: E501
collection_formats = {}
@@ -6520,10 +8210,10 @@ def read_namespaced_daemon_set_status_with_http_info(self, name, namespace, **kw
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -6536,6 +8226,11 @@ def read_namespaced_daemon_set_status_with_http_info(self, name, namespace, **kw
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1DaemonSet",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/daemonsets/{name}/status', 'GET',
path_params,
@@ -6544,13 +8239,14 @@ def read_namespaced_daemon_set_status_with_http_info(self, name, namespace, **kw
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1DaemonSet', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_deployment(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_deployment # noqa: E501
@@ -6558,23 +8254,30 @@ def read_namespaced_deployment(self, name, namespace, **kwargs): # noqa: E501
read the specified Deployment # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_deployment(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Deployment (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Deployment (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Deployment
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Deployment
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_deployment_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -6585,25 +8288,38 @@ def read_namespaced_deployment_with_http_info(self, name, namespace, **kwargs):
read the specified Deployment # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_deployment_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Deployment (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Deployment (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Deployment, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Deployment, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -6618,7 +8334,10 @@ def read_namespaced_deployment_with_http_info(self, name, namespace, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -6631,12 +8350,10 @@ def read_namespaced_deployment_with_http_info(self, name, namespace, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_deployment`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_deployment`") # noqa: E501
collection_formats = {}
@@ -6648,10 +8365,10 @@ def read_namespaced_deployment_with_http_info(self, name, namespace, **kwargs):
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -6664,6 +8381,11 @@ def read_namespaced_deployment_with_http_info(self, name, namespace, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Deployment",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/deployments/{name}', 'GET',
path_params,
@@ -6672,13 +8394,14 @@ def read_namespaced_deployment_with_http_info(self, name, namespace, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Deployment', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_deployment_scale(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_deployment_scale # noqa: E501
@@ -6686,23 +8409,30 @@ def read_namespaced_deployment_scale(self, name, namespace, **kwargs): # noqa:
read scale of the specified Deployment # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_deployment_scale(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Scale (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Scale (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Scale
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Scale
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_deployment_scale_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -6713,25 +8443,38 @@ def read_namespaced_deployment_scale_with_http_info(self, name, namespace, **kwa
read scale of the specified Deployment # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_deployment_scale_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Scale (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Scale (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Scale, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Scale, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -6746,7 +8489,10 @@ def read_namespaced_deployment_scale_with_http_info(self, name, namespace, **kwa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -6759,12 +8505,10 @@ def read_namespaced_deployment_scale_with_http_info(self, name, namespace, **kwa
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_deployment_scale`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_deployment_scale`") # noqa: E501
collection_formats = {}
@@ -6776,10 +8520,10 @@ def read_namespaced_deployment_scale_with_http_info(self, name, namespace, **kwa
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -6792,6 +8536,11 @@ def read_namespaced_deployment_scale_with_http_info(self, name, namespace, **kwa
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Scale",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/deployments/{name}/scale', 'GET',
path_params,
@@ -6800,13 +8549,14 @@ def read_namespaced_deployment_scale_with_http_info(self, name, namespace, **kwa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Scale', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_deployment_status(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_deployment_status # noqa: E501
@@ -6814,23 +8564,30 @@ def read_namespaced_deployment_status(self, name, namespace, **kwargs): # noqa:
read status of the specified Deployment # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_deployment_status(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Deployment (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Deployment (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Deployment
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Deployment
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_deployment_status_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -6841,25 +8598,38 @@ def read_namespaced_deployment_status_with_http_info(self, name, namespace, **kw
read status of the specified Deployment # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_deployment_status_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Deployment (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Deployment (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Deployment, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Deployment, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -6874,7 +8644,10 @@ def read_namespaced_deployment_status_with_http_info(self, name, namespace, **kw
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -6887,12 +8660,10 @@ def read_namespaced_deployment_status_with_http_info(self, name, namespace, **kw
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_deployment_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_deployment_status`") # noqa: E501
collection_formats = {}
@@ -6904,10 +8675,10 @@ def read_namespaced_deployment_status_with_http_info(self, name, namespace, **kw
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -6920,6 +8691,11 @@ def read_namespaced_deployment_status_with_http_info(self, name, namespace, **kw
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Deployment",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/deployments/{name}/status', 'GET',
path_params,
@@ -6928,13 +8704,14 @@ def read_namespaced_deployment_status_with_http_info(self, name, namespace, **kw
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Deployment', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_replica_set(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_replica_set # noqa: E501
@@ -6942,23 +8719,30 @@ def read_namespaced_replica_set(self, name, namespace, **kwargs): # noqa: E501
read the specified ReplicaSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_replica_set(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ReplicaSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ReplicaSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ReplicaSet
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ReplicaSet
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_replica_set_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -6969,25 +8753,38 @@ def read_namespaced_replica_set_with_http_info(self, name, namespace, **kwargs):
read the specified ReplicaSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_replica_set_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ReplicaSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ReplicaSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ReplicaSet, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ReplicaSet, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -7002,7 +8799,10 @@ def read_namespaced_replica_set_with_http_info(self, name, namespace, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -7015,12 +8815,10 @@ def read_namespaced_replica_set_with_http_info(self, name, namespace, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_replica_set`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_replica_set`") # noqa: E501
collection_formats = {}
@@ -7032,10 +8830,10 @@ def read_namespaced_replica_set_with_http_info(self, name, namespace, **kwargs):
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -7048,6 +8846,11 @@ def read_namespaced_replica_set_with_http_info(self, name, namespace, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ReplicaSet",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/replicasets/{name}', 'GET',
path_params,
@@ -7056,13 +8859,14 @@ def read_namespaced_replica_set_with_http_info(self, name, namespace, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ReplicaSet', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_replica_set_scale(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_replica_set_scale # noqa: E501
@@ -7070,23 +8874,30 @@ def read_namespaced_replica_set_scale(self, name, namespace, **kwargs): # noqa:
read scale of the specified ReplicaSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_replica_set_scale(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Scale (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Scale (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Scale
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Scale
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_replica_set_scale_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -7097,25 +8908,38 @@ def read_namespaced_replica_set_scale_with_http_info(self, name, namespace, **kw
read scale of the specified ReplicaSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_replica_set_scale_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Scale (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Scale (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Scale, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Scale, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -7130,7 +8954,10 @@ def read_namespaced_replica_set_scale_with_http_info(self, name, namespace, **kw
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -7143,12 +8970,10 @@ def read_namespaced_replica_set_scale_with_http_info(self, name, namespace, **kw
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_replica_set_scale`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_replica_set_scale`") # noqa: E501
collection_formats = {}
@@ -7160,10 +8985,10 @@ def read_namespaced_replica_set_scale_with_http_info(self, name, namespace, **kw
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -7176,6 +9001,11 @@ def read_namespaced_replica_set_scale_with_http_info(self, name, namespace, **kw
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Scale",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/replicasets/{name}/scale', 'GET',
path_params,
@@ -7184,13 +9014,14 @@ def read_namespaced_replica_set_scale_with_http_info(self, name, namespace, **kw
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Scale', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_replica_set_status(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_replica_set_status # noqa: E501
@@ -7198,23 +9029,30 @@ def read_namespaced_replica_set_status(self, name, namespace, **kwargs): # noqa
read status of the specified ReplicaSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_replica_set_status(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ReplicaSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ReplicaSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ReplicaSet
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ReplicaSet
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_replica_set_status_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -7225,25 +9063,38 @@ def read_namespaced_replica_set_status_with_http_info(self, name, namespace, **k
read status of the specified ReplicaSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_replica_set_status_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ReplicaSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ReplicaSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ReplicaSet, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ReplicaSet, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -7258,7 +9109,10 @@ def read_namespaced_replica_set_status_with_http_info(self, name, namespace, **k
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -7271,12 +9125,10 @@ def read_namespaced_replica_set_status_with_http_info(self, name, namespace, **k
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_replica_set_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_replica_set_status`") # noqa: E501
collection_formats = {}
@@ -7288,10 +9140,10 @@ def read_namespaced_replica_set_status_with_http_info(self, name, namespace, **k
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -7304,6 +9156,11 @@ def read_namespaced_replica_set_status_with_http_info(self, name, namespace, **k
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ReplicaSet",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/replicasets/{name}/status', 'GET',
path_params,
@@ -7312,13 +9169,14 @@ def read_namespaced_replica_set_status_with_http_info(self, name, namespace, **k
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ReplicaSet', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_stateful_set(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_stateful_set # noqa: E501
@@ -7326,23 +9184,30 @@ def read_namespaced_stateful_set(self, name, namespace, **kwargs): # noqa: E501
read the specified StatefulSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_stateful_set(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the StatefulSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the StatefulSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1StatefulSet
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1StatefulSet
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_stateful_set_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -7353,25 +9218,38 @@ def read_namespaced_stateful_set_with_http_info(self, name, namespace, **kwargs)
read the specified StatefulSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_stateful_set_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the StatefulSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the StatefulSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1StatefulSet, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1StatefulSet, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -7386,7 +9264,10 @@ def read_namespaced_stateful_set_with_http_info(self, name, namespace, **kwargs)
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -7399,12 +9280,10 @@ def read_namespaced_stateful_set_with_http_info(self, name, namespace, **kwargs)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_stateful_set`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_stateful_set`") # noqa: E501
collection_formats = {}
@@ -7416,10 +9295,10 @@ def read_namespaced_stateful_set_with_http_info(self, name, namespace, **kwargs)
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -7432,6 +9311,11 @@ def read_namespaced_stateful_set_with_http_info(self, name, namespace, **kwargs)
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1StatefulSet",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/statefulsets/{name}', 'GET',
path_params,
@@ -7440,13 +9324,14 @@ def read_namespaced_stateful_set_with_http_info(self, name, namespace, **kwargs)
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1StatefulSet', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_stateful_set_scale(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_stateful_set_scale # noqa: E501
@@ -7454,23 +9339,30 @@ def read_namespaced_stateful_set_scale(self, name, namespace, **kwargs): # noqa
read scale of the specified StatefulSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_stateful_set_scale(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Scale (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Scale (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Scale
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Scale
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_stateful_set_scale_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -7481,25 +9373,38 @@ def read_namespaced_stateful_set_scale_with_http_info(self, name, namespace, **k
read scale of the specified StatefulSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_stateful_set_scale_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Scale (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Scale (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Scale, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Scale, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -7514,7 +9419,10 @@ def read_namespaced_stateful_set_scale_with_http_info(self, name, namespace, **k
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -7527,12 +9435,10 @@ def read_namespaced_stateful_set_scale_with_http_info(self, name, namespace, **k
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_stateful_set_scale`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_stateful_set_scale`") # noqa: E501
collection_formats = {}
@@ -7544,10 +9450,10 @@ def read_namespaced_stateful_set_scale_with_http_info(self, name, namespace, **k
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -7560,6 +9466,11 @@ def read_namespaced_stateful_set_scale_with_http_info(self, name, namespace, **k
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Scale",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/statefulsets/{name}/scale', 'GET',
path_params,
@@ -7568,13 +9479,14 @@ def read_namespaced_stateful_set_scale_with_http_info(self, name, namespace, **k
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Scale', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_stateful_set_status(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_stateful_set_status # noqa: E501
@@ -7582,23 +9494,30 @@ def read_namespaced_stateful_set_status(self, name, namespace, **kwargs): # noq
read status of the specified StatefulSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_stateful_set_status(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the StatefulSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the StatefulSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1StatefulSet
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1StatefulSet
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_stateful_set_status_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -7609,25 +9528,38 @@ def read_namespaced_stateful_set_status_with_http_info(self, name, namespace, **
read status of the specified StatefulSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_stateful_set_status_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the StatefulSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the StatefulSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1StatefulSet, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1StatefulSet, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -7642,7 +9574,10 @@ def read_namespaced_stateful_set_status_with_http_info(self, name, namespace, **
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -7655,12 +9590,10 @@ def read_namespaced_stateful_set_status_with_http_info(self, name, namespace, **
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_stateful_set_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_stateful_set_status`") # noqa: E501
collection_formats = {}
@@ -7672,10 +9605,10 @@ def read_namespaced_stateful_set_status_with_http_info(self, name, namespace, **
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -7688,6 +9621,11 @@ def read_namespaced_stateful_set_status_with_http_info(self, name, namespace, **
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1StatefulSet",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/statefulsets/{name}/status', 'GET',
path_params,
@@ -7696,13 +9634,14 @@ def read_namespaced_stateful_set_status_with_http_info(self, name, namespace, **
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1StatefulSet', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_controller_revision(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_controller_revision # noqa: E501
@@ -7710,27 +9649,38 @@ def replace_namespaced_controller_revision(self, name, namespace, body, **kwargs
replace the specified ControllerRevision # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_controller_revision(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ControllerRevision (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ControllerRevision body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ControllerRevision (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ControllerRevision
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ControllerRevision
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ControllerRevision
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_controller_revision_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -7741,29 +9691,46 @@ def replace_namespaced_controller_revision_with_http_info(self, name, namespace,
replace the specified ControllerRevision # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_controller_revision_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ControllerRevision (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ControllerRevision body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ControllerRevision (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ControllerRevision
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ControllerRevision, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ControllerRevision, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -7782,7 +9749,10 @@ def replace_namespaced_controller_revision_with_http_info(self, name, namespace,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -7795,16 +9765,13 @@ def replace_namespaced_controller_revision_with_http_info(self, name, namespace,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_controller_revision`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_controller_revision`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_controller_revision`") # noqa: E501
collection_formats = {}
@@ -7816,16 +9783,16 @@ def replace_namespaced_controller_revision_with_http_info(self, name, namespace,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -7840,6 +9807,12 @@ def replace_namespaced_controller_revision_with_http_info(self, name, namespace,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ControllerRevision",
+ 201: "V1ControllerRevision",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/controllerrevisions/{name}', 'PUT',
path_params,
@@ -7848,13 +9821,14 @@ def replace_namespaced_controller_revision_with_http_info(self, name, namespace,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ControllerRevision', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_daemon_set(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_daemon_set # noqa: E501
@@ -7862,27 +9836,38 @@ def replace_namespaced_daemon_set(self, name, namespace, body, **kwargs): # noq
replace the specified DaemonSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_daemon_set(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the DaemonSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1DaemonSet body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the DaemonSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1DaemonSet
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1DaemonSet
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1DaemonSet
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_daemon_set_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -7893,29 +9878,46 @@ def replace_namespaced_daemon_set_with_http_info(self, name, namespace, body, **
replace the specified DaemonSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_daemon_set_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the DaemonSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1DaemonSet body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the DaemonSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1DaemonSet
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1DaemonSet, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1DaemonSet, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -7934,7 +9936,10 @@ def replace_namespaced_daemon_set_with_http_info(self, name, namespace, body, **
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -7947,16 +9952,13 @@ def replace_namespaced_daemon_set_with_http_info(self, name, namespace, body, **
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_daemon_set`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_daemon_set`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_daemon_set`") # noqa: E501
collection_formats = {}
@@ -7968,16 +9970,16 @@ def replace_namespaced_daemon_set_with_http_info(self, name, namespace, body, **
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -7992,6 +9994,12 @@ def replace_namespaced_daemon_set_with_http_info(self, name, namespace, body, **
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1DaemonSet",
+ 201: "V1DaemonSet",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/daemonsets/{name}', 'PUT',
path_params,
@@ -8000,13 +10008,14 @@ def replace_namespaced_daemon_set_with_http_info(self, name, namespace, body, **
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1DaemonSet', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_daemon_set_status(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_daemon_set_status # noqa: E501
@@ -8014,27 +10023,38 @@ def replace_namespaced_daemon_set_status(self, name, namespace, body, **kwargs):
replace status of the specified DaemonSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_daemon_set_status(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the DaemonSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1DaemonSet body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the DaemonSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1DaemonSet
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1DaemonSet
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1DaemonSet
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_daemon_set_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -8045,29 +10065,46 @@ def replace_namespaced_daemon_set_status_with_http_info(self, name, namespace, b
replace status of the specified DaemonSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_daemon_set_status_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the DaemonSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1DaemonSet body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the DaemonSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1DaemonSet
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1DaemonSet, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1DaemonSet, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -8086,7 +10123,10 @@ def replace_namespaced_daemon_set_status_with_http_info(self, name, namespace, b
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -8099,16 +10139,13 @@ def replace_namespaced_daemon_set_status_with_http_info(self, name, namespace, b
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_daemon_set_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_daemon_set_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_daemon_set_status`") # noqa: E501
collection_formats = {}
@@ -8120,16 +10157,16 @@ def replace_namespaced_daemon_set_status_with_http_info(self, name, namespace, b
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -8144,6 +10181,12 @@ def replace_namespaced_daemon_set_status_with_http_info(self, name, namespace, b
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1DaemonSet",
+ 201: "V1DaemonSet",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/daemonsets/{name}/status', 'PUT',
path_params,
@@ -8152,13 +10195,14 @@ def replace_namespaced_daemon_set_status_with_http_info(self, name, namespace, b
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1DaemonSet', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_deployment(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_deployment # noqa: E501
@@ -8166,27 +10210,38 @@ def replace_namespaced_deployment(self, name, namespace, body, **kwargs): # noq
replace the specified Deployment # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_deployment(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Deployment (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Deployment body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Deployment (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Deployment
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Deployment
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Deployment
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_deployment_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -8197,29 +10252,46 @@ def replace_namespaced_deployment_with_http_info(self, name, namespace, body, **
replace the specified Deployment # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_deployment_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Deployment (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Deployment body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Deployment (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Deployment
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Deployment, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Deployment, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -8238,7 +10310,10 @@ def replace_namespaced_deployment_with_http_info(self, name, namespace, body, **
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -8251,16 +10326,13 @@ def replace_namespaced_deployment_with_http_info(self, name, namespace, body, **
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_deployment`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_deployment`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_deployment`") # noqa: E501
collection_formats = {}
@@ -8272,16 +10344,16 @@ def replace_namespaced_deployment_with_http_info(self, name, namespace, body, **
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -8296,6 +10368,12 @@ def replace_namespaced_deployment_with_http_info(self, name, namespace, body, **
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Deployment",
+ 201: "V1Deployment",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/deployments/{name}', 'PUT',
path_params,
@@ -8304,13 +10382,14 @@ def replace_namespaced_deployment_with_http_info(self, name, namespace, body, **
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Deployment', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_deployment_scale(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_deployment_scale # noqa: E501
@@ -8318,27 +10397,38 @@ def replace_namespaced_deployment_scale(self, name, namespace, body, **kwargs):
replace scale of the specified Deployment # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_deployment_scale(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Scale (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Scale body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Scale (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Scale
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Scale
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Scale
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_deployment_scale_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -8349,29 +10439,46 @@ def replace_namespaced_deployment_scale_with_http_info(self, name, namespace, bo
replace scale of the specified Deployment # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_deployment_scale_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Scale (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Scale body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Scale (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Scale
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Scale, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Scale, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -8390,7 +10497,10 @@ def replace_namespaced_deployment_scale_with_http_info(self, name, namespace, bo
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -8403,16 +10513,13 @@ def replace_namespaced_deployment_scale_with_http_info(self, name, namespace, bo
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_deployment_scale`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_deployment_scale`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_deployment_scale`") # noqa: E501
collection_formats = {}
@@ -8424,16 +10531,16 @@ def replace_namespaced_deployment_scale_with_http_info(self, name, namespace, bo
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -8448,6 +10555,12 @@ def replace_namespaced_deployment_scale_with_http_info(self, name, namespace, bo
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Scale",
+ 201: "V1Scale",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/deployments/{name}/scale', 'PUT',
path_params,
@@ -8456,13 +10569,14 @@ def replace_namespaced_deployment_scale_with_http_info(self, name, namespace, bo
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Scale', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_deployment_status(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_deployment_status # noqa: E501
@@ -8470,27 +10584,38 @@ def replace_namespaced_deployment_status(self, name, namespace, body, **kwargs):
replace status of the specified Deployment # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_deployment_status(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Deployment (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Deployment body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Deployment (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Deployment
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Deployment
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Deployment
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_deployment_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -8501,29 +10626,46 @@ def replace_namespaced_deployment_status_with_http_info(self, name, namespace, b
replace status of the specified Deployment # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_deployment_status_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Deployment (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Deployment body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Deployment (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Deployment
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Deployment, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Deployment, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -8542,7 +10684,10 @@ def replace_namespaced_deployment_status_with_http_info(self, name, namespace, b
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -8555,16 +10700,13 @@ def replace_namespaced_deployment_status_with_http_info(self, name, namespace, b
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_deployment_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_deployment_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_deployment_status`") # noqa: E501
collection_formats = {}
@@ -8576,16 +10718,16 @@ def replace_namespaced_deployment_status_with_http_info(self, name, namespace, b
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -8600,6 +10742,12 @@ def replace_namespaced_deployment_status_with_http_info(self, name, namespace, b
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Deployment",
+ 201: "V1Deployment",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/deployments/{name}/status', 'PUT',
path_params,
@@ -8608,13 +10756,14 @@ def replace_namespaced_deployment_status_with_http_info(self, name, namespace, b
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Deployment', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_replica_set(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_replica_set # noqa: E501
@@ -8622,27 +10771,38 @@ def replace_namespaced_replica_set(self, name, namespace, body, **kwargs): # no
replace the specified ReplicaSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_replica_set(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ReplicaSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ReplicaSet body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ReplicaSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ReplicaSet
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ReplicaSet
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ReplicaSet
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_replica_set_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -8653,29 +10813,46 @@ def replace_namespaced_replica_set_with_http_info(self, name, namespace, body, *
replace the specified ReplicaSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_replica_set_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ReplicaSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ReplicaSet body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ReplicaSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ReplicaSet
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ReplicaSet, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ReplicaSet, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -8694,7 +10871,10 @@ def replace_namespaced_replica_set_with_http_info(self, name, namespace, body, *
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -8707,16 +10887,13 @@ def replace_namespaced_replica_set_with_http_info(self, name, namespace, body, *
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_replica_set`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_replica_set`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_replica_set`") # noqa: E501
collection_formats = {}
@@ -8728,16 +10905,16 @@ def replace_namespaced_replica_set_with_http_info(self, name, namespace, body, *
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -8752,6 +10929,12 @@ def replace_namespaced_replica_set_with_http_info(self, name, namespace, body, *
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ReplicaSet",
+ 201: "V1ReplicaSet",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/replicasets/{name}', 'PUT',
path_params,
@@ -8760,13 +10943,14 @@ def replace_namespaced_replica_set_with_http_info(self, name, namespace, body, *
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ReplicaSet', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_replica_set_scale(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_replica_set_scale # noqa: E501
@@ -8774,27 +10958,38 @@ def replace_namespaced_replica_set_scale(self, name, namespace, body, **kwargs):
replace scale of the specified ReplicaSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_replica_set_scale(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Scale (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Scale body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Scale (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Scale
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Scale
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Scale
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_replica_set_scale_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -8805,29 +11000,46 @@ def replace_namespaced_replica_set_scale_with_http_info(self, name, namespace, b
replace scale of the specified ReplicaSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_replica_set_scale_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Scale (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Scale body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Scale (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Scale
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Scale, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Scale, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -8846,7 +11058,10 @@ def replace_namespaced_replica_set_scale_with_http_info(self, name, namespace, b
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -8859,16 +11074,13 @@ def replace_namespaced_replica_set_scale_with_http_info(self, name, namespace, b
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_replica_set_scale`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_replica_set_scale`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_replica_set_scale`") # noqa: E501
collection_formats = {}
@@ -8880,16 +11092,16 @@ def replace_namespaced_replica_set_scale_with_http_info(self, name, namespace, b
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -8904,6 +11116,12 @@ def replace_namespaced_replica_set_scale_with_http_info(self, name, namespace, b
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Scale",
+ 201: "V1Scale",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/replicasets/{name}/scale', 'PUT',
path_params,
@@ -8912,13 +11130,14 @@ def replace_namespaced_replica_set_scale_with_http_info(self, name, namespace, b
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Scale', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_replica_set_status(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_replica_set_status # noqa: E501
@@ -8926,27 +11145,38 @@ def replace_namespaced_replica_set_status(self, name, namespace, body, **kwargs)
replace status of the specified ReplicaSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_replica_set_status(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ReplicaSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ReplicaSet body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ReplicaSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ReplicaSet
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ReplicaSet
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ReplicaSet
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_replica_set_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -8957,29 +11187,46 @@ def replace_namespaced_replica_set_status_with_http_info(self, name, namespace,
replace status of the specified ReplicaSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_replica_set_status_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ReplicaSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ReplicaSet body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ReplicaSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ReplicaSet
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ReplicaSet, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ReplicaSet, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -8998,7 +11245,10 @@ def replace_namespaced_replica_set_status_with_http_info(self, name, namespace,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -9011,16 +11261,13 @@ def replace_namespaced_replica_set_status_with_http_info(self, name, namespace,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_replica_set_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_replica_set_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_replica_set_status`") # noqa: E501
collection_formats = {}
@@ -9032,16 +11279,16 @@ def replace_namespaced_replica_set_status_with_http_info(self, name, namespace,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -9056,6 +11303,12 @@ def replace_namespaced_replica_set_status_with_http_info(self, name, namespace,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ReplicaSet",
+ 201: "V1ReplicaSet",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/replicasets/{name}/status', 'PUT',
path_params,
@@ -9064,13 +11317,14 @@ def replace_namespaced_replica_set_status_with_http_info(self, name, namespace,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ReplicaSet', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_stateful_set(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_stateful_set # noqa: E501
@@ -9078,27 +11332,38 @@ def replace_namespaced_stateful_set(self, name, namespace, body, **kwargs): # n
replace the specified StatefulSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_stateful_set(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the StatefulSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1StatefulSet body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the StatefulSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1StatefulSet
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1StatefulSet
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1StatefulSet
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_stateful_set_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -9109,29 +11374,46 @@ def replace_namespaced_stateful_set_with_http_info(self, name, namespace, body,
replace the specified StatefulSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_stateful_set_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the StatefulSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1StatefulSet body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the StatefulSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1StatefulSet
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1StatefulSet, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1StatefulSet, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -9150,7 +11432,10 @@ def replace_namespaced_stateful_set_with_http_info(self, name, namespace, body,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -9163,16 +11448,13 @@ def replace_namespaced_stateful_set_with_http_info(self, name, namespace, body,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_stateful_set`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_stateful_set`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_stateful_set`") # noqa: E501
collection_formats = {}
@@ -9184,16 +11466,16 @@ def replace_namespaced_stateful_set_with_http_info(self, name, namespace, body,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -9208,6 +11490,12 @@ def replace_namespaced_stateful_set_with_http_info(self, name, namespace, body,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1StatefulSet",
+ 201: "V1StatefulSet",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/statefulsets/{name}', 'PUT',
path_params,
@@ -9216,13 +11504,14 @@ def replace_namespaced_stateful_set_with_http_info(self, name, namespace, body,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1StatefulSet', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_stateful_set_scale(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_stateful_set_scale # noqa: E501
@@ -9230,27 +11519,38 @@ def replace_namespaced_stateful_set_scale(self, name, namespace, body, **kwargs)
replace scale of the specified StatefulSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_stateful_set_scale(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Scale (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Scale body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Scale (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Scale
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Scale
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Scale
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_stateful_set_scale_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -9261,29 +11561,46 @@ def replace_namespaced_stateful_set_scale_with_http_info(self, name, namespace,
replace scale of the specified StatefulSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_stateful_set_scale_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Scale (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Scale body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Scale (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Scale
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Scale, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Scale, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -9302,7 +11619,10 @@ def replace_namespaced_stateful_set_scale_with_http_info(self, name, namespace,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -9315,16 +11635,13 @@ def replace_namespaced_stateful_set_scale_with_http_info(self, name, namespace,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_stateful_set_scale`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_stateful_set_scale`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_stateful_set_scale`") # noqa: E501
collection_formats = {}
@@ -9336,16 +11653,16 @@ def replace_namespaced_stateful_set_scale_with_http_info(self, name, namespace,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -9360,6 +11677,12 @@ def replace_namespaced_stateful_set_scale_with_http_info(self, name, namespace,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Scale",
+ 201: "V1Scale",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/statefulsets/{name}/scale', 'PUT',
path_params,
@@ -9368,13 +11691,14 @@ def replace_namespaced_stateful_set_scale_with_http_info(self, name, namespace,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Scale', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_stateful_set_status(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_stateful_set_status # noqa: E501
@@ -9382,27 +11706,38 @@ def replace_namespaced_stateful_set_status(self, name, namespace, body, **kwargs
replace status of the specified StatefulSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_stateful_set_status(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the StatefulSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1StatefulSet body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the StatefulSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1StatefulSet
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1StatefulSet
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1StatefulSet
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_stateful_set_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -9413,29 +11748,46 @@ def replace_namespaced_stateful_set_status_with_http_info(self, name, namespace,
replace status of the specified StatefulSet # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_stateful_set_status_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the StatefulSet (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1StatefulSet body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the StatefulSet (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1StatefulSet
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1StatefulSet, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1StatefulSet, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -9454,7 +11806,10 @@ def replace_namespaced_stateful_set_status_with_http_info(self, name, namespace,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -9467,16 +11822,13 @@ def replace_namespaced_stateful_set_status_with_http_info(self, name, namespace,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_stateful_set_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_stateful_set_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_stateful_set_status`") # noqa: E501
collection_formats = {}
@@ -9488,16 +11840,16 @@ def replace_namespaced_stateful_set_status_with_http_info(self, name, namespace,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -9512,6 +11864,12 @@ def replace_namespaced_stateful_set_status_with_http_info(self, name, namespace,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1StatefulSet",
+ 201: "V1StatefulSet",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/apps/v1/namespaces/{namespace}/statefulsets/{name}/status', 'PUT',
path_params,
@@ -9520,10 +11878,11 @@ def replace_namespaced_stateful_set_status_with_http_info(self, name, namespace,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1StatefulSet', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/authentication_api.py b/kubernetes/client/api/authentication_api.py
index a05e2ad1c7..940d2e27d3 100644
--- a/kubernetes/client/api/authentication_api.py
+++ b/kubernetes/client/api/authentication_api.py
@@ -42,20 +42,24 @@ def get_api_group(self, **kwargs): # noqa: E501
get information of a group # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_group(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIGroup
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIGroup
"""
kwargs['_return_http_data_only'] = True
return self.get_api_group_with_http_info(**kwargs) # noqa: E501
@@ -66,22 +70,32 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
get information of a group # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_group_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIGroup, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIGroup, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -93,7 +107,10 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -112,7 +129,7 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -125,6 +142,11 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIGroup",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/authentication.k8s.io/', 'GET',
path_params,
@@ -133,10 +155,11 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIGroup', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/authentication_v1_api.py b/kubernetes/client/api/authentication_v1_api.py
index ebc5f74e99..93941360f3 100644
--- a/kubernetes/client/api/authentication_v1_api.py
+++ b/kubernetes/client/api/authentication_v1_api.py
@@ -42,25 +42,34 @@ def create_self_subject_review(self, body, **kwargs): # noqa: E501
create a SelfSubjectReview # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_self_subject_review(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1SelfSubjectReview body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param body: (required)
+ :type body: V1SelfSubjectReview
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1SelfSubjectReview
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1SelfSubjectReview
"""
kwargs['_return_http_data_only'] = True
return self.create_self_subject_review_with_http_info(body, **kwargs) # noqa: E501
@@ -71,27 +80,42 @@ def create_self_subject_review_with_http_info(self, body, **kwargs): # noqa: E5
create a SelfSubjectReview # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_self_subject_review_with_http_info(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1SelfSubjectReview body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param body: (required)
+ :type body: V1SelfSubjectReview
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1SelfSubjectReview, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1SelfSubjectReview, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -108,7 +132,10 @@ def create_self_subject_review_with_http_info(self, body, **kwargs): # noqa: E5
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -121,8 +148,7 @@ def create_self_subject_review_with_http_info(self, body, **kwargs): # noqa: E5
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_self_subject_review`") # noqa: E501
collection_formats = {}
@@ -130,16 +156,16 @@ def create_self_subject_review_with_http_info(self, body, **kwargs): # noqa: E5
path_params = {}
query_params = []
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -154,6 +180,13 @@ def create_self_subject_review_with_http_info(self, body, **kwargs): # noqa: E5
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1SelfSubjectReview",
+ 201: "V1SelfSubjectReview",
+ 202: "V1SelfSubjectReview",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/authentication.k8s.io/v1/selfsubjectreviews', 'POST',
path_params,
@@ -162,13 +195,14 @@ def create_self_subject_review_with_http_info(self, body, **kwargs): # noqa: E5
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1SelfSubjectReview', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_token_review(self, body, **kwargs): # noqa: E501
"""create_token_review # noqa: E501
@@ -176,25 +210,34 @@ def create_token_review(self, body, **kwargs): # noqa: E501
create a TokenReview # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_token_review(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1TokenReview body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param body: (required)
+ :type body: V1TokenReview
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1TokenReview
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1TokenReview
"""
kwargs['_return_http_data_only'] = True
return self.create_token_review_with_http_info(body, **kwargs) # noqa: E501
@@ -205,27 +248,42 @@ def create_token_review_with_http_info(self, body, **kwargs): # noqa: E501
create a TokenReview # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_token_review_with_http_info(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1TokenReview body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param body: (required)
+ :type body: V1TokenReview
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1TokenReview, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1TokenReview, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -242,7 +300,10 @@ def create_token_review_with_http_info(self, body, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -255,8 +316,7 @@ def create_token_review_with_http_info(self, body, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_token_review`") # noqa: E501
collection_formats = {}
@@ -264,16 +324,16 @@ def create_token_review_with_http_info(self, body, **kwargs): # noqa: E501
path_params = {}
query_params = []
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -288,6 +348,13 @@ def create_token_review_with_http_info(self, body, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1TokenReview",
+ 201: "V1TokenReview",
+ 202: "V1TokenReview",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/authentication.k8s.io/v1/tokenreviews', 'POST',
path_params,
@@ -296,13 +363,14 @@ def create_token_review_with_http_info(self, body, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1TokenReview', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def get_api_resources(self, **kwargs): # noqa: E501
"""get_api_resources # noqa: E501
@@ -310,20 +378,24 @@ def get_api_resources(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIResourceList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIResourceList
"""
kwargs['_return_http_data_only'] = True
return self.get_api_resources_with_http_info(**kwargs) # noqa: E501
@@ -334,22 +406,32 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -361,7 +443,10 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -380,7 +465,7 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -393,6 +478,11 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIResourceList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/authentication.k8s.io/v1/', 'GET',
path_params,
@@ -401,10 +491,11 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIResourceList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/authorization_api.py b/kubernetes/client/api/authorization_api.py
index 0c599c4468..3273bbf074 100644
--- a/kubernetes/client/api/authorization_api.py
+++ b/kubernetes/client/api/authorization_api.py
@@ -42,20 +42,24 @@ def get_api_group(self, **kwargs): # noqa: E501
get information of a group # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_group(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIGroup
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIGroup
"""
kwargs['_return_http_data_only'] = True
return self.get_api_group_with_http_info(**kwargs) # noqa: E501
@@ -66,22 +70,32 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
get information of a group # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_group_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIGroup, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIGroup, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -93,7 +107,10 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -112,7 +129,7 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -125,6 +142,11 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIGroup",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/authorization.k8s.io/', 'GET',
path_params,
@@ -133,10 +155,11 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIGroup', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/authorization_v1_api.py b/kubernetes/client/api/authorization_v1_api.py
index 653ddca302..0d9a83e21b 100644
--- a/kubernetes/client/api/authorization_v1_api.py
+++ b/kubernetes/client/api/authorization_v1_api.py
@@ -42,26 +42,36 @@ def create_namespaced_local_subject_access_review(self, namespace, body, **kwarg
create a LocalSubjectAccessReview # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_local_subject_access_review(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1LocalSubjectAccessReview body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1LocalSubjectAccessReview
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1LocalSubjectAccessReview
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1LocalSubjectAccessReview
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_local_subject_access_review_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -72,28 +82,44 @@ def create_namespaced_local_subject_access_review_with_http_info(self, namespace
create a LocalSubjectAccessReview # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_local_subject_access_review_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1LocalSubjectAccessReview body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1LocalSubjectAccessReview
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1LocalSubjectAccessReview, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1LocalSubjectAccessReview, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -111,7 +137,10 @@ def create_namespaced_local_subject_access_review_with_http_info(self, namespace
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -124,12 +153,10 @@ def create_namespaced_local_subject_access_review_with_http_info(self, namespace
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_local_subject_access_review`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_local_subject_access_review`") # noqa: E501
collection_formats = {}
@@ -139,16 +166,16 @@ def create_namespaced_local_subject_access_review_with_http_info(self, namespace
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -163,6 +190,13 @@ def create_namespaced_local_subject_access_review_with_http_info(self, namespace
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1LocalSubjectAccessReview",
+ 201: "V1LocalSubjectAccessReview",
+ 202: "V1LocalSubjectAccessReview",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/authorization.k8s.io/v1/namespaces/{namespace}/localsubjectaccessreviews', 'POST',
path_params,
@@ -171,13 +205,14 @@ def create_namespaced_local_subject_access_review_with_http_info(self, namespace
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1LocalSubjectAccessReview', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_self_subject_access_review(self, body, **kwargs): # noqa: E501
"""create_self_subject_access_review # noqa: E501
@@ -185,25 +220,34 @@ def create_self_subject_access_review(self, body, **kwargs): # noqa: E501
create a SelfSubjectAccessReview # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_self_subject_access_review(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1SelfSubjectAccessReview body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param body: (required)
+ :type body: V1SelfSubjectAccessReview
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1SelfSubjectAccessReview
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1SelfSubjectAccessReview
"""
kwargs['_return_http_data_only'] = True
return self.create_self_subject_access_review_with_http_info(body, **kwargs) # noqa: E501
@@ -214,27 +258,42 @@ def create_self_subject_access_review_with_http_info(self, body, **kwargs): # n
create a SelfSubjectAccessReview # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_self_subject_access_review_with_http_info(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1SelfSubjectAccessReview body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param body: (required)
+ :type body: V1SelfSubjectAccessReview
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1SelfSubjectAccessReview, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1SelfSubjectAccessReview, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -251,7 +310,10 @@ def create_self_subject_access_review_with_http_info(self, body, **kwargs): # n
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -264,8 +326,7 @@ def create_self_subject_access_review_with_http_info(self, body, **kwargs): # n
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_self_subject_access_review`") # noqa: E501
collection_formats = {}
@@ -273,16 +334,16 @@ def create_self_subject_access_review_with_http_info(self, body, **kwargs): # n
path_params = {}
query_params = []
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -297,6 +358,13 @@ def create_self_subject_access_review_with_http_info(self, body, **kwargs): # n
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1SelfSubjectAccessReview",
+ 201: "V1SelfSubjectAccessReview",
+ 202: "V1SelfSubjectAccessReview",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/authorization.k8s.io/v1/selfsubjectaccessreviews', 'POST',
path_params,
@@ -305,13 +373,14 @@ def create_self_subject_access_review_with_http_info(self, body, **kwargs): # n
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1SelfSubjectAccessReview', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_self_subject_rules_review(self, body, **kwargs): # noqa: E501
"""create_self_subject_rules_review # noqa: E501
@@ -319,25 +388,34 @@ def create_self_subject_rules_review(self, body, **kwargs): # noqa: E501
create a SelfSubjectRulesReview # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_self_subject_rules_review(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1SelfSubjectRulesReview body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param body: (required)
+ :type body: V1SelfSubjectRulesReview
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1SelfSubjectRulesReview
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1SelfSubjectRulesReview
"""
kwargs['_return_http_data_only'] = True
return self.create_self_subject_rules_review_with_http_info(body, **kwargs) # noqa: E501
@@ -348,27 +426,42 @@ def create_self_subject_rules_review_with_http_info(self, body, **kwargs): # no
create a SelfSubjectRulesReview # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_self_subject_rules_review_with_http_info(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1SelfSubjectRulesReview body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param body: (required)
+ :type body: V1SelfSubjectRulesReview
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1SelfSubjectRulesReview, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1SelfSubjectRulesReview, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -385,7 +478,10 @@ def create_self_subject_rules_review_with_http_info(self, body, **kwargs): # no
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -398,8 +494,7 @@ def create_self_subject_rules_review_with_http_info(self, body, **kwargs): # no
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_self_subject_rules_review`") # noqa: E501
collection_formats = {}
@@ -407,16 +502,16 @@ def create_self_subject_rules_review_with_http_info(self, body, **kwargs): # no
path_params = {}
query_params = []
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -431,6 +526,13 @@ def create_self_subject_rules_review_with_http_info(self, body, **kwargs): # no
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1SelfSubjectRulesReview",
+ 201: "V1SelfSubjectRulesReview",
+ 202: "V1SelfSubjectRulesReview",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/authorization.k8s.io/v1/selfsubjectrulesreviews', 'POST',
path_params,
@@ -439,13 +541,14 @@ def create_self_subject_rules_review_with_http_info(self, body, **kwargs): # no
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1SelfSubjectRulesReview', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_subject_access_review(self, body, **kwargs): # noqa: E501
"""create_subject_access_review # noqa: E501
@@ -453,25 +556,34 @@ def create_subject_access_review(self, body, **kwargs): # noqa: E501
create a SubjectAccessReview # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_subject_access_review(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1SubjectAccessReview body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param body: (required)
+ :type body: V1SubjectAccessReview
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1SubjectAccessReview
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1SubjectAccessReview
"""
kwargs['_return_http_data_only'] = True
return self.create_subject_access_review_with_http_info(body, **kwargs) # noqa: E501
@@ -482,27 +594,42 @@ def create_subject_access_review_with_http_info(self, body, **kwargs): # noqa:
create a SubjectAccessReview # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_subject_access_review_with_http_info(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1SubjectAccessReview body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param body: (required)
+ :type body: V1SubjectAccessReview
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1SubjectAccessReview, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1SubjectAccessReview, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -519,7 +646,10 @@ def create_subject_access_review_with_http_info(self, body, **kwargs): # noqa:
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -532,8 +662,7 @@ def create_subject_access_review_with_http_info(self, body, **kwargs): # noqa:
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_subject_access_review`") # noqa: E501
collection_formats = {}
@@ -541,16 +670,16 @@ def create_subject_access_review_with_http_info(self, body, **kwargs): # noqa:
path_params = {}
query_params = []
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -565,6 +694,13 @@ def create_subject_access_review_with_http_info(self, body, **kwargs): # noqa:
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1SubjectAccessReview",
+ 201: "V1SubjectAccessReview",
+ 202: "V1SubjectAccessReview",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/authorization.k8s.io/v1/subjectaccessreviews', 'POST',
path_params,
@@ -573,13 +709,14 @@ def create_subject_access_review_with_http_info(self, body, **kwargs): # noqa:
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1SubjectAccessReview', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def get_api_resources(self, **kwargs): # noqa: E501
"""get_api_resources # noqa: E501
@@ -587,20 +724,24 @@ def get_api_resources(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIResourceList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIResourceList
"""
kwargs['_return_http_data_only'] = True
return self.get_api_resources_with_http_info(**kwargs) # noqa: E501
@@ -611,22 +752,32 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -638,7 +789,10 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -657,7 +811,7 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -670,6 +824,11 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIResourceList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/authorization.k8s.io/v1/', 'GET',
path_params,
@@ -678,10 +837,11 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIResourceList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/autoscaling_api.py b/kubernetes/client/api/autoscaling_api.py
index 7d5ec76eaf..23c1393e9a 100644
--- a/kubernetes/client/api/autoscaling_api.py
+++ b/kubernetes/client/api/autoscaling_api.py
@@ -42,20 +42,24 @@ def get_api_group(self, **kwargs): # noqa: E501
get information of a group # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_group(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIGroup
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIGroup
"""
kwargs['_return_http_data_only'] = True
return self.get_api_group_with_http_info(**kwargs) # noqa: E501
@@ -66,22 +70,32 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
get information of a group # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_group_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIGroup, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIGroup, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -93,7 +107,10 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -112,7 +129,7 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -125,6 +142,11 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIGroup",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/autoscaling/', 'GET',
path_params,
@@ -133,10 +155,11 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIGroup', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/autoscaling_v1_api.py b/kubernetes/client/api/autoscaling_v1_api.py
index bd131c21c0..8d55106130 100644
--- a/kubernetes/client/api/autoscaling_v1_api.py
+++ b/kubernetes/client/api/autoscaling_v1_api.py
@@ -42,26 +42,36 @@ def create_namespaced_horizontal_pod_autoscaler(self, namespace, body, **kwargs)
create a HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_horizontal_pod_autoscaler(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1HorizontalPodAutoscaler body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1HorizontalPodAutoscaler
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1HorizontalPodAutoscaler
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1HorizontalPodAutoscaler
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_horizontal_pod_autoscaler_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -72,28 +82,44 @@ def create_namespaced_horizontal_pod_autoscaler_with_http_info(self, namespace,
create a HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_horizontal_pod_autoscaler_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1HorizontalPodAutoscaler body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1HorizontalPodAutoscaler
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1HorizontalPodAutoscaler, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1HorizontalPodAutoscaler, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -111,7 +137,10 @@ def create_namespaced_horizontal_pod_autoscaler_with_http_info(self, namespace,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -124,12 +153,10 @@ def create_namespaced_horizontal_pod_autoscaler_with_http_info(self, namespace,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_horizontal_pod_autoscaler`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_horizontal_pod_autoscaler`") # noqa: E501
collection_formats = {}
@@ -139,16 +166,16 @@ def create_namespaced_horizontal_pod_autoscaler_with_http_info(self, namespace,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -163,6 +190,13 @@ def create_namespaced_horizontal_pod_autoscaler_with_http_info(self, namespace,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1HorizontalPodAutoscaler",
+ 201: "V1HorizontalPodAutoscaler",
+ 202: "V1HorizontalPodAutoscaler",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/autoscaling/v1/namespaces/{namespace}/horizontalpodautoscalers', 'POST',
path_params,
@@ -171,13 +205,14 @@ def create_namespaced_horizontal_pod_autoscaler_with_http_info(self, namespace,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1HorizontalPodAutoscaler', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_namespaced_horizontal_pod_autoscaler(self, namespace, **kwargs): # noqa: E501
"""delete_collection_namespaced_horizontal_pod_autoscaler # noqa: E501
@@ -185,36 +220,56 @@ def delete_collection_namespaced_horizontal_pod_autoscaler(self, namespace, **kw
delete collection of HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_horizontal_pod_autoscaler(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_namespaced_horizontal_pod_autoscaler_with_http_info(namespace, **kwargs) # noqa: E501
@@ -225,38 +280,64 @@ def delete_collection_namespaced_horizontal_pod_autoscaler_with_http_info(self,
delete collection of HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_horizontal_pod_autoscaler_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -284,7 +365,10 @@ def delete_collection_namespaced_horizontal_pod_autoscaler_with_http_info(self,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -297,8 +381,7 @@ def delete_collection_namespaced_horizontal_pod_autoscaler_with_http_info(self,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_horizontal_pod_autoscaler`") # noqa: E501
collection_formats = {}
@@ -308,36 +391,36 @@ def delete_collection_namespaced_horizontal_pod_autoscaler_with_http_info(self,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -352,6 +435,11 @@ def delete_collection_namespaced_horizontal_pod_autoscaler_with_http_info(self,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/autoscaling/v1/namespaces/{namespace}/horizontalpodautoscalers', 'DELETE',
path_params,
@@ -360,13 +448,14 @@ def delete_collection_namespaced_horizontal_pod_autoscaler_with_http_info(self,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_namespaced_horizontal_pod_autoscaler(self, name, namespace, **kwargs): # noqa: E501
"""delete_namespaced_horizontal_pod_autoscaler # noqa: E501
@@ -374,29 +463,42 @@ def delete_namespaced_horizontal_pod_autoscaler(self, name, namespace, **kwargs)
delete a HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_horizontal_pod_autoscaler(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the HorizontalPodAutoscaler (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the HorizontalPodAutoscaler (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_namespaced_horizontal_pod_autoscaler_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -407,31 +509,50 @@ def delete_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, names
delete a HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_horizontal_pod_autoscaler_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the HorizontalPodAutoscaler (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the HorizontalPodAutoscaler (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -452,7 +573,10 @@ def delete_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, names
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -465,12 +589,10 @@ def delete_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, names
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_horizontal_pod_autoscaler`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_horizontal_pod_autoscaler`") # noqa: E501
collection_formats = {}
@@ -482,20 +604,20 @@ def delete_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, names
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -510,6 +632,12 @@ def delete_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, names
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/autoscaling/v1/namespaces/{namespace}/horizontalpodautoscalers/{name}', 'DELETE',
path_params,
@@ -518,13 +646,14 @@ def delete_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, names
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def get_api_resources(self, **kwargs): # noqa: E501
"""get_api_resources # noqa: E501
@@ -532,20 +661,24 @@ def get_api_resources(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIResourceList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIResourceList
"""
kwargs['_return_http_data_only'] = True
return self.get_api_resources_with_http_info(**kwargs) # noqa: E501
@@ -556,22 +689,32 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -583,7 +726,10 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -602,7 +748,7 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -615,6 +761,11 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIResourceList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/autoscaling/v1/', 'GET',
path_params,
@@ -623,13 +774,14 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIResourceList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_horizontal_pod_autoscaler_for_all_namespaces(self, **kwargs): # noqa: E501
"""list_horizontal_pod_autoscaler_for_all_namespaces # noqa: E501
@@ -637,31 +789,46 @@ def list_horizontal_pod_autoscaler_for_all_namespaces(self, **kwargs): # noqa:
list or watch objects of kind HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_horizontal_pod_autoscaler_for_all_namespaces(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1HorizontalPodAutoscalerList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1HorizontalPodAutoscalerList
"""
kwargs['_return_http_data_only'] = True
return self.list_horizontal_pod_autoscaler_for_all_namespaces_with_http_info(**kwargs) # noqa: E501
@@ -672,33 +839,54 @@ def list_horizontal_pod_autoscaler_for_all_namespaces_with_http_info(self, **kwa
list or watch objects of kind HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_horizontal_pod_autoscaler_for_all_namespaces_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1HorizontalPodAutoscalerList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1HorizontalPodAutoscalerList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -721,7 +909,10 @@ def list_horizontal_pod_autoscaler_for_all_namespaces_with_http_info(self, **kwa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -739,30 +930,30 @@ def list_horizontal_pod_autoscaler_for_all_namespaces_with_http_info(self, **kwa
path_params = {}
query_params = []
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -775,6 +966,11 @@ def list_horizontal_pod_autoscaler_for_all_namespaces_with_http_info(self, **kwa
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1HorizontalPodAutoscalerList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/autoscaling/v1/horizontalpodautoscalers', 'GET',
path_params,
@@ -783,13 +979,14 @@ def list_horizontal_pod_autoscaler_for_all_namespaces_with_http_info(self, **kwa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1HorizontalPodAutoscalerList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_namespaced_horizontal_pod_autoscaler(self, namespace, **kwargs): # noqa: E501
"""list_namespaced_horizontal_pod_autoscaler # noqa: E501
@@ -797,32 +994,48 @@ def list_namespaced_horizontal_pod_autoscaler(self, namespace, **kwargs): # noq
list or watch objects of kind HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_horizontal_pod_autoscaler(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1HorizontalPodAutoscalerList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1HorizontalPodAutoscalerList
"""
kwargs['_return_http_data_only'] = True
return self.list_namespaced_horizontal_pod_autoscaler_with_http_info(namespace, **kwargs) # noqa: E501
@@ -833,34 +1046,56 @@ def list_namespaced_horizontal_pod_autoscaler_with_http_info(self, namespace, **
list or watch objects of kind HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_horizontal_pod_autoscaler_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1HorizontalPodAutoscalerList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1HorizontalPodAutoscalerList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -884,7 +1119,10 @@ def list_namespaced_horizontal_pod_autoscaler_with_http_info(self, namespace, **
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -897,8 +1135,7 @@ def list_namespaced_horizontal_pod_autoscaler_with_http_info(self, namespace, **
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_horizontal_pod_autoscaler`") # noqa: E501
collection_formats = {}
@@ -908,30 +1145,30 @@ def list_namespaced_horizontal_pod_autoscaler_with_http_info(self, namespace, **
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -944,6 +1181,11 @@ def list_namespaced_horizontal_pod_autoscaler_with_http_info(self, namespace, **
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1HorizontalPodAutoscalerList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/autoscaling/v1/namespaces/{namespace}/horizontalpodautoscalers', 'GET',
path_params,
@@ -952,13 +1194,14 @@ def list_namespaced_horizontal_pod_autoscaler_with_http_info(self, namespace, **
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1HorizontalPodAutoscalerList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_horizontal_pod_autoscaler(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_horizontal_pod_autoscaler # noqa: E501
@@ -966,28 +1209,40 @@ def patch_namespaced_horizontal_pod_autoscaler(self, name, namespace, body, **kw
partially update the specified HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_horizontal_pod_autoscaler(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the HorizontalPodAutoscaler (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the HorizontalPodAutoscaler (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1HorizontalPodAutoscaler
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1HorizontalPodAutoscaler
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_horizontal_pod_autoscaler_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -998,30 +1253,48 @@ def patch_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, namesp
partially update the specified HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_horizontal_pod_autoscaler_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the HorizontalPodAutoscaler (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the HorizontalPodAutoscaler (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1HorizontalPodAutoscaler, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1HorizontalPodAutoscaler, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1041,7 +1314,10 @@ def patch_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, namesp
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1054,16 +1330,13 @@ def patch_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, namesp
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_horizontal_pod_autoscaler`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_horizontal_pod_autoscaler`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_horizontal_pod_autoscaler`") # noqa: E501
collection_formats = {}
@@ -1075,18 +1348,18 @@ def patch_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, namesp
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1099,12 +1372,22 @@ def patch_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, namesp
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1HorizontalPodAutoscaler",
+ 201: "V1HorizontalPodAutoscaler",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/autoscaling/v1/namespaces/{namespace}/horizontalpodautoscalers/{name}', 'PATCH',
path_params,
@@ -1113,13 +1396,14 @@ def patch_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, namesp
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1HorizontalPodAutoscaler', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_horizontal_pod_autoscaler_status(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_horizontal_pod_autoscaler_status # noqa: E501
@@ -1127,28 +1411,40 @@ def patch_namespaced_horizontal_pod_autoscaler_status(self, name, namespace, bod
partially update status of the specified HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_horizontal_pod_autoscaler_status(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the HorizontalPodAutoscaler (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the HorizontalPodAutoscaler (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1HorizontalPodAutoscaler
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1HorizontalPodAutoscaler
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_horizontal_pod_autoscaler_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -1159,30 +1455,48 @@ def patch_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, name,
partially update status of the specified HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_horizontal_pod_autoscaler_status_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the HorizontalPodAutoscaler (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the HorizontalPodAutoscaler (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1HorizontalPodAutoscaler, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1HorizontalPodAutoscaler, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1202,7 +1516,10 @@ def patch_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, name,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1215,16 +1532,13 @@ def patch_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, name,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_horizontal_pod_autoscaler_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_horizontal_pod_autoscaler_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_horizontal_pod_autoscaler_status`") # noqa: E501
collection_formats = {}
@@ -1236,18 +1550,18 @@ def patch_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, name,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1260,12 +1574,22 @@ def patch_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, name,
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1HorizontalPodAutoscaler",
+ 201: "V1HorizontalPodAutoscaler",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/autoscaling/v1/namespaces/{namespace}/horizontalpodautoscalers/{name}/status', 'PATCH',
path_params,
@@ -1274,13 +1598,14 @@ def patch_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, name,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1HorizontalPodAutoscaler', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_horizontal_pod_autoscaler(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_horizontal_pod_autoscaler # noqa: E501
@@ -1288,23 +1613,30 @@ def read_namespaced_horizontal_pod_autoscaler(self, name, namespace, **kwargs):
read the specified HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_horizontal_pod_autoscaler(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the HorizontalPodAutoscaler (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the HorizontalPodAutoscaler (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1HorizontalPodAutoscaler
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1HorizontalPodAutoscaler
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_horizontal_pod_autoscaler_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -1315,25 +1647,38 @@ def read_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, namespa
read the specified HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_horizontal_pod_autoscaler_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the HorizontalPodAutoscaler (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the HorizontalPodAutoscaler (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1HorizontalPodAutoscaler, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1HorizontalPodAutoscaler, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1348,7 +1693,10 @@ def read_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, namespa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1361,12 +1709,10 @@ def read_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, namespa
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_horizontal_pod_autoscaler`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_horizontal_pod_autoscaler`") # noqa: E501
collection_formats = {}
@@ -1378,10 +1724,10 @@ def read_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, namespa
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1394,6 +1740,11 @@ def read_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, namespa
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1HorizontalPodAutoscaler",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/autoscaling/v1/namespaces/{namespace}/horizontalpodautoscalers/{name}', 'GET',
path_params,
@@ -1402,13 +1753,14 @@ def read_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, namespa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1HorizontalPodAutoscaler', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_horizontal_pod_autoscaler_status(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_horizontal_pod_autoscaler_status # noqa: E501
@@ -1416,23 +1768,30 @@ def read_namespaced_horizontal_pod_autoscaler_status(self, name, namespace, **kw
read status of the specified HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_horizontal_pod_autoscaler_status(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the HorizontalPodAutoscaler (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the HorizontalPodAutoscaler (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1HorizontalPodAutoscaler
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1HorizontalPodAutoscaler
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_horizontal_pod_autoscaler_status_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -1443,25 +1802,38 @@ def read_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, name,
read status of the specified HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_horizontal_pod_autoscaler_status_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the HorizontalPodAutoscaler (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the HorizontalPodAutoscaler (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1HorizontalPodAutoscaler, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1HorizontalPodAutoscaler, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1476,7 +1848,10 @@ def read_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, name,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1489,12 +1864,10 @@ def read_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, name,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_horizontal_pod_autoscaler_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_horizontal_pod_autoscaler_status`") # noqa: E501
collection_formats = {}
@@ -1506,10 +1879,10 @@ def read_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, name,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1522,6 +1895,11 @@ def read_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, name,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1HorizontalPodAutoscaler",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/autoscaling/v1/namespaces/{namespace}/horizontalpodautoscalers/{name}/status', 'GET',
path_params,
@@ -1530,13 +1908,14 @@ def read_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, name,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1HorizontalPodAutoscaler', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_horizontal_pod_autoscaler(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_horizontal_pod_autoscaler # noqa: E501
@@ -1544,27 +1923,38 @@ def replace_namespaced_horizontal_pod_autoscaler(self, name, namespace, body, **
replace the specified HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_horizontal_pod_autoscaler(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the HorizontalPodAutoscaler (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1HorizontalPodAutoscaler body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the HorizontalPodAutoscaler (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1HorizontalPodAutoscaler
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1HorizontalPodAutoscaler
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1HorizontalPodAutoscaler
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_horizontal_pod_autoscaler_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -1575,29 +1965,46 @@ def replace_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, name
replace the specified HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_horizontal_pod_autoscaler_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the HorizontalPodAutoscaler (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1HorizontalPodAutoscaler body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the HorizontalPodAutoscaler (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1HorizontalPodAutoscaler
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1HorizontalPodAutoscaler, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1HorizontalPodAutoscaler, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1616,7 +2023,10 @@ def replace_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, name
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1629,16 +2039,13 @@ def replace_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, name
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_horizontal_pod_autoscaler`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_horizontal_pod_autoscaler`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_horizontal_pod_autoscaler`") # noqa: E501
collection_formats = {}
@@ -1650,16 +2057,16 @@ def replace_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, name
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1674,6 +2081,12 @@ def replace_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, name
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1HorizontalPodAutoscaler",
+ 201: "V1HorizontalPodAutoscaler",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/autoscaling/v1/namespaces/{namespace}/horizontalpodautoscalers/{name}', 'PUT',
path_params,
@@ -1682,13 +2095,14 @@ def replace_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, name
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1HorizontalPodAutoscaler', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_horizontal_pod_autoscaler_status(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_horizontal_pod_autoscaler_status # noqa: E501
@@ -1696,27 +2110,38 @@ def replace_namespaced_horizontal_pod_autoscaler_status(self, name, namespace, b
replace status of the specified HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_horizontal_pod_autoscaler_status(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the HorizontalPodAutoscaler (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1HorizontalPodAutoscaler body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the HorizontalPodAutoscaler (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1HorizontalPodAutoscaler
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1HorizontalPodAutoscaler
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1HorizontalPodAutoscaler
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_horizontal_pod_autoscaler_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -1727,29 +2152,46 @@ def replace_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, nam
replace status of the specified HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_horizontal_pod_autoscaler_status_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the HorizontalPodAutoscaler (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1HorizontalPodAutoscaler body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the HorizontalPodAutoscaler (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1HorizontalPodAutoscaler
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1HorizontalPodAutoscaler, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1HorizontalPodAutoscaler, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1768,7 +2210,10 @@ def replace_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, nam
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1781,16 +2226,13 @@ def replace_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, nam
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_horizontal_pod_autoscaler_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_horizontal_pod_autoscaler_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_horizontal_pod_autoscaler_status`") # noqa: E501
collection_formats = {}
@@ -1802,16 +2244,16 @@ def replace_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, nam
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1826,6 +2268,12 @@ def replace_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, nam
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1HorizontalPodAutoscaler",
+ 201: "V1HorizontalPodAutoscaler",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/autoscaling/v1/namespaces/{namespace}/horizontalpodautoscalers/{name}/status', 'PUT',
path_params,
@@ -1834,10 +2282,11 @@ def replace_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, nam
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1HorizontalPodAutoscaler', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/autoscaling_v2_api.py b/kubernetes/client/api/autoscaling_v2_api.py
index 7405e9bc0f..061c3dd956 100644
--- a/kubernetes/client/api/autoscaling_v2_api.py
+++ b/kubernetes/client/api/autoscaling_v2_api.py
@@ -42,26 +42,36 @@ def create_namespaced_horizontal_pod_autoscaler(self, namespace, body, **kwargs)
create a HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_horizontal_pod_autoscaler(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V2HorizontalPodAutoscaler body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V2HorizontalPodAutoscaler
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V2HorizontalPodAutoscaler
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V2HorizontalPodAutoscaler
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_horizontal_pod_autoscaler_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -72,28 +82,44 @@ def create_namespaced_horizontal_pod_autoscaler_with_http_info(self, namespace,
create a HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_horizontal_pod_autoscaler_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V2HorizontalPodAutoscaler body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V2HorizontalPodAutoscaler
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V2HorizontalPodAutoscaler, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V2HorizontalPodAutoscaler, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -111,7 +137,10 @@ def create_namespaced_horizontal_pod_autoscaler_with_http_info(self, namespace,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -124,12 +153,10 @@ def create_namespaced_horizontal_pod_autoscaler_with_http_info(self, namespace,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_horizontal_pod_autoscaler`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_horizontal_pod_autoscaler`") # noqa: E501
collection_formats = {}
@@ -139,16 +166,16 @@ def create_namespaced_horizontal_pod_autoscaler_with_http_info(self, namespace,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -163,6 +190,13 @@ def create_namespaced_horizontal_pod_autoscaler_with_http_info(self, namespace,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V2HorizontalPodAutoscaler",
+ 201: "V2HorizontalPodAutoscaler",
+ 202: "V2HorizontalPodAutoscaler",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/autoscaling/v2/namespaces/{namespace}/horizontalpodautoscalers', 'POST',
path_params,
@@ -171,13 +205,14 @@ def create_namespaced_horizontal_pod_autoscaler_with_http_info(self, namespace,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V2HorizontalPodAutoscaler', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_namespaced_horizontal_pod_autoscaler(self, namespace, **kwargs): # noqa: E501
"""delete_collection_namespaced_horizontal_pod_autoscaler # noqa: E501
@@ -185,36 +220,56 @@ def delete_collection_namespaced_horizontal_pod_autoscaler(self, namespace, **kw
delete collection of HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_horizontal_pod_autoscaler(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_namespaced_horizontal_pod_autoscaler_with_http_info(namespace, **kwargs) # noqa: E501
@@ -225,38 +280,64 @@ def delete_collection_namespaced_horizontal_pod_autoscaler_with_http_info(self,
delete collection of HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_horizontal_pod_autoscaler_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -284,7 +365,10 @@ def delete_collection_namespaced_horizontal_pod_autoscaler_with_http_info(self,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -297,8 +381,7 @@ def delete_collection_namespaced_horizontal_pod_autoscaler_with_http_info(self,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_horizontal_pod_autoscaler`") # noqa: E501
collection_formats = {}
@@ -308,36 +391,36 @@ def delete_collection_namespaced_horizontal_pod_autoscaler_with_http_info(self,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -352,6 +435,11 @@ def delete_collection_namespaced_horizontal_pod_autoscaler_with_http_info(self,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/autoscaling/v2/namespaces/{namespace}/horizontalpodautoscalers', 'DELETE',
path_params,
@@ -360,13 +448,14 @@ def delete_collection_namespaced_horizontal_pod_autoscaler_with_http_info(self,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_namespaced_horizontal_pod_autoscaler(self, name, namespace, **kwargs): # noqa: E501
"""delete_namespaced_horizontal_pod_autoscaler # noqa: E501
@@ -374,29 +463,42 @@ def delete_namespaced_horizontal_pod_autoscaler(self, name, namespace, **kwargs)
delete a HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_horizontal_pod_autoscaler(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the HorizontalPodAutoscaler (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the HorizontalPodAutoscaler (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_namespaced_horizontal_pod_autoscaler_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -407,31 +509,50 @@ def delete_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, names
delete a HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_horizontal_pod_autoscaler_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the HorizontalPodAutoscaler (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the HorizontalPodAutoscaler (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -452,7 +573,10 @@ def delete_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, names
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -465,12 +589,10 @@ def delete_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, names
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_horizontal_pod_autoscaler`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_horizontal_pod_autoscaler`") # noqa: E501
collection_formats = {}
@@ -482,20 +604,20 @@ def delete_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, names
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -510,6 +632,12 @@ def delete_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, names
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/autoscaling/v2/namespaces/{namespace}/horizontalpodautoscalers/{name}', 'DELETE',
path_params,
@@ -518,13 +646,14 @@ def delete_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, names
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def get_api_resources(self, **kwargs): # noqa: E501
"""get_api_resources # noqa: E501
@@ -532,20 +661,24 @@ def get_api_resources(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIResourceList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIResourceList
"""
kwargs['_return_http_data_only'] = True
return self.get_api_resources_with_http_info(**kwargs) # noqa: E501
@@ -556,22 +689,32 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -583,7 +726,10 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -602,7 +748,7 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -615,6 +761,11 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIResourceList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/autoscaling/v2/', 'GET',
path_params,
@@ -623,13 +774,14 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIResourceList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_horizontal_pod_autoscaler_for_all_namespaces(self, **kwargs): # noqa: E501
"""list_horizontal_pod_autoscaler_for_all_namespaces # noqa: E501
@@ -637,31 +789,46 @@ def list_horizontal_pod_autoscaler_for_all_namespaces(self, **kwargs): # noqa:
list or watch objects of kind HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_horizontal_pod_autoscaler_for_all_namespaces(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V2HorizontalPodAutoscalerList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V2HorizontalPodAutoscalerList
"""
kwargs['_return_http_data_only'] = True
return self.list_horizontal_pod_autoscaler_for_all_namespaces_with_http_info(**kwargs) # noqa: E501
@@ -672,33 +839,54 @@ def list_horizontal_pod_autoscaler_for_all_namespaces_with_http_info(self, **kwa
list or watch objects of kind HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_horizontal_pod_autoscaler_for_all_namespaces_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V2HorizontalPodAutoscalerList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V2HorizontalPodAutoscalerList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -721,7 +909,10 @@ def list_horizontal_pod_autoscaler_for_all_namespaces_with_http_info(self, **kwa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -739,30 +930,30 @@ def list_horizontal_pod_autoscaler_for_all_namespaces_with_http_info(self, **kwa
path_params = {}
query_params = []
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -775,6 +966,11 @@ def list_horizontal_pod_autoscaler_for_all_namespaces_with_http_info(self, **kwa
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V2HorizontalPodAutoscalerList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/autoscaling/v2/horizontalpodautoscalers', 'GET',
path_params,
@@ -783,13 +979,14 @@ def list_horizontal_pod_autoscaler_for_all_namespaces_with_http_info(self, **kwa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V2HorizontalPodAutoscalerList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_namespaced_horizontal_pod_autoscaler(self, namespace, **kwargs): # noqa: E501
"""list_namespaced_horizontal_pod_autoscaler # noqa: E501
@@ -797,32 +994,48 @@ def list_namespaced_horizontal_pod_autoscaler(self, namespace, **kwargs): # noq
list or watch objects of kind HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_horizontal_pod_autoscaler(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V2HorizontalPodAutoscalerList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V2HorizontalPodAutoscalerList
"""
kwargs['_return_http_data_only'] = True
return self.list_namespaced_horizontal_pod_autoscaler_with_http_info(namespace, **kwargs) # noqa: E501
@@ -833,34 +1046,56 @@ def list_namespaced_horizontal_pod_autoscaler_with_http_info(self, namespace, **
list or watch objects of kind HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_horizontal_pod_autoscaler_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V2HorizontalPodAutoscalerList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V2HorizontalPodAutoscalerList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -884,7 +1119,10 @@ def list_namespaced_horizontal_pod_autoscaler_with_http_info(self, namespace, **
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -897,8 +1135,7 @@ def list_namespaced_horizontal_pod_autoscaler_with_http_info(self, namespace, **
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_horizontal_pod_autoscaler`") # noqa: E501
collection_formats = {}
@@ -908,30 +1145,30 @@ def list_namespaced_horizontal_pod_autoscaler_with_http_info(self, namespace, **
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -944,6 +1181,11 @@ def list_namespaced_horizontal_pod_autoscaler_with_http_info(self, namespace, **
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V2HorizontalPodAutoscalerList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/autoscaling/v2/namespaces/{namespace}/horizontalpodautoscalers', 'GET',
path_params,
@@ -952,13 +1194,14 @@ def list_namespaced_horizontal_pod_autoscaler_with_http_info(self, namespace, **
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V2HorizontalPodAutoscalerList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_horizontal_pod_autoscaler(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_horizontal_pod_autoscaler # noqa: E501
@@ -966,28 +1209,40 @@ def patch_namespaced_horizontal_pod_autoscaler(self, name, namespace, body, **kw
partially update the specified HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_horizontal_pod_autoscaler(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the HorizontalPodAutoscaler (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the HorizontalPodAutoscaler (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V2HorizontalPodAutoscaler
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V2HorizontalPodAutoscaler
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_horizontal_pod_autoscaler_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -998,30 +1253,48 @@ def patch_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, namesp
partially update the specified HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_horizontal_pod_autoscaler_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the HorizontalPodAutoscaler (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the HorizontalPodAutoscaler (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V2HorizontalPodAutoscaler, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V2HorizontalPodAutoscaler, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1041,7 +1314,10 @@ def patch_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, namesp
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1054,16 +1330,13 @@ def patch_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, namesp
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_horizontal_pod_autoscaler`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_horizontal_pod_autoscaler`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_horizontal_pod_autoscaler`") # noqa: E501
collection_formats = {}
@@ -1075,18 +1348,18 @@ def patch_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, namesp
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1099,12 +1372,22 @@ def patch_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, namesp
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V2HorizontalPodAutoscaler",
+ 201: "V2HorizontalPodAutoscaler",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/autoscaling/v2/namespaces/{namespace}/horizontalpodautoscalers/{name}', 'PATCH',
path_params,
@@ -1113,13 +1396,14 @@ def patch_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, namesp
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V2HorizontalPodAutoscaler', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_horizontal_pod_autoscaler_status(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_horizontal_pod_autoscaler_status # noqa: E501
@@ -1127,28 +1411,40 @@ def patch_namespaced_horizontal_pod_autoscaler_status(self, name, namespace, bod
partially update status of the specified HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_horizontal_pod_autoscaler_status(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the HorizontalPodAutoscaler (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the HorizontalPodAutoscaler (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V2HorizontalPodAutoscaler
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V2HorizontalPodAutoscaler
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_horizontal_pod_autoscaler_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -1159,30 +1455,48 @@ def patch_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, name,
partially update status of the specified HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_horizontal_pod_autoscaler_status_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the HorizontalPodAutoscaler (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the HorizontalPodAutoscaler (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V2HorizontalPodAutoscaler, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V2HorizontalPodAutoscaler, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1202,7 +1516,10 @@ def patch_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, name,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1215,16 +1532,13 @@ def patch_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, name,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_horizontal_pod_autoscaler_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_horizontal_pod_autoscaler_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_horizontal_pod_autoscaler_status`") # noqa: E501
collection_formats = {}
@@ -1236,18 +1550,18 @@ def patch_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, name,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1260,12 +1574,22 @@ def patch_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, name,
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V2HorizontalPodAutoscaler",
+ 201: "V2HorizontalPodAutoscaler",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/autoscaling/v2/namespaces/{namespace}/horizontalpodautoscalers/{name}/status', 'PATCH',
path_params,
@@ -1274,13 +1598,14 @@ def patch_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, name,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V2HorizontalPodAutoscaler', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_horizontal_pod_autoscaler(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_horizontal_pod_autoscaler # noqa: E501
@@ -1288,23 +1613,30 @@ def read_namespaced_horizontal_pod_autoscaler(self, name, namespace, **kwargs):
read the specified HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_horizontal_pod_autoscaler(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the HorizontalPodAutoscaler (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the HorizontalPodAutoscaler (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V2HorizontalPodAutoscaler
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V2HorizontalPodAutoscaler
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_horizontal_pod_autoscaler_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -1315,25 +1647,38 @@ def read_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, namespa
read the specified HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_horizontal_pod_autoscaler_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the HorizontalPodAutoscaler (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the HorizontalPodAutoscaler (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V2HorizontalPodAutoscaler, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V2HorizontalPodAutoscaler, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1348,7 +1693,10 @@ def read_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, namespa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1361,12 +1709,10 @@ def read_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, namespa
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_horizontal_pod_autoscaler`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_horizontal_pod_autoscaler`") # noqa: E501
collection_formats = {}
@@ -1378,10 +1724,10 @@ def read_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, namespa
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1394,6 +1740,11 @@ def read_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, namespa
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V2HorizontalPodAutoscaler",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/autoscaling/v2/namespaces/{namespace}/horizontalpodautoscalers/{name}', 'GET',
path_params,
@@ -1402,13 +1753,14 @@ def read_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, namespa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V2HorizontalPodAutoscaler', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_horizontal_pod_autoscaler_status(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_horizontal_pod_autoscaler_status # noqa: E501
@@ -1416,23 +1768,30 @@ def read_namespaced_horizontal_pod_autoscaler_status(self, name, namespace, **kw
read status of the specified HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_horizontal_pod_autoscaler_status(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the HorizontalPodAutoscaler (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the HorizontalPodAutoscaler (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V2HorizontalPodAutoscaler
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V2HorizontalPodAutoscaler
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_horizontal_pod_autoscaler_status_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -1443,25 +1802,38 @@ def read_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, name,
read status of the specified HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_horizontal_pod_autoscaler_status_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the HorizontalPodAutoscaler (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the HorizontalPodAutoscaler (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V2HorizontalPodAutoscaler, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V2HorizontalPodAutoscaler, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1476,7 +1848,10 @@ def read_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, name,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1489,12 +1864,10 @@ def read_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, name,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_horizontal_pod_autoscaler_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_horizontal_pod_autoscaler_status`") # noqa: E501
collection_formats = {}
@@ -1506,10 +1879,10 @@ def read_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, name,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1522,6 +1895,11 @@ def read_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, name,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V2HorizontalPodAutoscaler",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/autoscaling/v2/namespaces/{namespace}/horizontalpodautoscalers/{name}/status', 'GET',
path_params,
@@ -1530,13 +1908,14 @@ def read_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, name,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V2HorizontalPodAutoscaler', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_horizontal_pod_autoscaler(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_horizontal_pod_autoscaler # noqa: E501
@@ -1544,27 +1923,38 @@ def replace_namespaced_horizontal_pod_autoscaler(self, name, namespace, body, **
replace the specified HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_horizontal_pod_autoscaler(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the HorizontalPodAutoscaler (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V2HorizontalPodAutoscaler body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the HorizontalPodAutoscaler (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V2HorizontalPodAutoscaler
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V2HorizontalPodAutoscaler
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V2HorizontalPodAutoscaler
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_horizontal_pod_autoscaler_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -1575,29 +1965,46 @@ def replace_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, name
replace the specified HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_horizontal_pod_autoscaler_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the HorizontalPodAutoscaler (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V2HorizontalPodAutoscaler body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the HorizontalPodAutoscaler (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V2HorizontalPodAutoscaler
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V2HorizontalPodAutoscaler, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V2HorizontalPodAutoscaler, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1616,7 +2023,10 @@ def replace_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, name
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1629,16 +2039,13 @@ def replace_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, name
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_horizontal_pod_autoscaler`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_horizontal_pod_autoscaler`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_horizontal_pod_autoscaler`") # noqa: E501
collection_formats = {}
@@ -1650,16 +2057,16 @@ def replace_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, name
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1674,6 +2081,12 @@ def replace_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, name
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V2HorizontalPodAutoscaler",
+ 201: "V2HorizontalPodAutoscaler",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/autoscaling/v2/namespaces/{namespace}/horizontalpodautoscalers/{name}', 'PUT',
path_params,
@@ -1682,13 +2095,14 @@ def replace_namespaced_horizontal_pod_autoscaler_with_http_info(self, name, name
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V2HorizontalPodAutoscaler', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_horizontal_pod_autoscaler_status(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_horizontal_pod_autoscaler_status # noqa: E501
@@ -1696,27 +2110,38 @@ def replace_namespaced_horizontal_pod_autoscaler_status(self, name, namespace, b
replace status of the specified HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_horizontal_pod_autoscaler_status(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the HorizontalPodAutoscaler (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V2HorizontalPodAutoscaler body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the HorizontalPodAutoscaler (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V2HorizontalPodAutoscaler
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V2HorizontalPodAutoscaler
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V2HorizontalPodAutoscaler
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_horizontal_pod_autoscaler_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -1727,29 +2152,46 @@ def replace_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, nam
replace status of the specified HorizontalPodAutoscaler # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_horizontal_pod_autoscaler_status_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the HorizontalPodAutoscaler (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V2HorizontalPodAutoscaler body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the HorizontalPodAutoscaler (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V2HorizontalPodAutoscaler
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V2HorizontalPodAutoscaler, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V2HorizontalPodAutoscaler, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1768,7 +2210,10 @@ def replace_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, nam
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1781,16 +2226,13 @@ def replace_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, nam
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_horizontal_pod_autoscaler_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_horizontal_pod_autoscaler_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_horizontal_pod_autoscaler_status`") # noqa: E501
collection_formats = {}
@@ -1802,16 +2244,16 @@ def replace_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, nam
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1826,6 +2268,12 @@ def replace_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, nam
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V2HorizontalPodAutoscaler",
+ 201: "V2HorizontalPodAutoscaler",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/autoscaling/v2/namespaces/{namespace}/horizontalpodautoscalers/{name}/status', 'PUT',
path_params,
@@ -1834,10 +2282,11 @@ def replace_namespaced_horizontal_pod_autoscaler_status_with_http_info(self, nam
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V2HorizontalPodAutoscaler', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/batch_api.py b/kubernetes/client/api/batch_api.py
index 156eafcba2..fec0323b0d 100644
--- a/kubernetes/client/api/batch_api.py
+++ b/kubernetes/client/api/batch_api.py
@@ -42,20 +42,24 @@ def get_api_group(self, **kwargs): # noqa: E501
get information of a group # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_group(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIGroup
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIGroup
"""
kwargs['_return_http_data_only'] = True
return self.get_api_group_with_http_info(**kwargs) # noqa: E501
@@ -66,22 +70,32 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
get information of a group # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_group_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIGroup, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIGroup, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -93,7 +107,10 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -112,7 +129,7 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -125,6 +142,11 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIGroup",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/batch/', 'GET',
path_params,
@@ -133,10 +155,11 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIGroup', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/batch_v1_api.py b/kubernetes/client/api/batch_v1_api.py
index aaf45f957d..50ef107763 100644
--- a/kubernetes/client/api/batch_v1_api.py
+++ b/kubernetes/client/api/batch_v1_api.py
@@ -42,26 +42,36 @@ def create_namespaced_cron_job(self, namespace, body, **kwargs): # noqa: E501
create a CronJob # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_cron_job(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1CronJob body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1CronJob
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1CronJob
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1CronJob
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_cron_job_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -72,28 +82,44 @@ def create_namespaced_cron_job_with_http_info(self, namespace, body, **kwargs):
create a CronJob # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_cron_job_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1CronJob body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1CronJob
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1CronJob, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1CronJob, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -111,7 +137,10 @@ def create_namespaced_cron_job_with_http_info(self, namespace, body, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -124,12 +153,10 @@ def create_namespaced_cron_job_with_http_info(self, namespace, body, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_cron_job`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_cron_job`") # noqa: E501
collection_formats = {}
@@ -139,16 +166,16 @@ def create_namespaced_cron_job_with_http_info(self, namespace, body, **kwargs):
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -163,6 +190,13 @@ def create_namespaced_cron_job_with_http_info(self, namespace, body, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1CronJob",
+ 201: "V1CronJob",
+ 202: "V1CronJob",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/batch/v1/namespaces/{namespace}/cronjobs', 'POST',
path_params,
@@ -171,13 +205,14 @@ def create_namespaced_cron_job_with_http_info(self, namespace, body, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1CronJob', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_namespaced_job(self, namespace, body, **kwargs): # noqa: E501
"""create_namespaced_job # noqa: E501
@@ -185,26 +220,36 @@ def create_namespaced_job(self, namespace, body, **kwargs): # noqa: E501
create a Job # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_job(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Job body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Job
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Job
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Job
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_job_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -215,28 +260,44 @@ def create_namespaced_job_with_http_info(self, namespace, body, **kwargs): # no
create a Job # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_job_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Job body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Job
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Job, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Job, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -254,7 +315,10 @@ def create_namespaced_job_with_http_info(self, namespace, body, **kwargs): # no
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -267,12 +331,10 @@ def create_namespaced_job_with_http_info(self, namespace, body, **kwargs): # no
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_job`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_job`") # noqa: E501
collection_formats = {}
@@ -282,16 +344,16 @@ def create_namespaced_job_with_http_info(self, namespace, body, **kwargs): # no
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -306,6 +368,13 @@ def create_namespaced_job_with_http_info(self, namespace, body, **kwargs): # no
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Job",
+ 201: "V1Job",
+ 202: "V1Job",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/batch/v1/namespaces/{namespace}/jobs', 'POST',
path_params,
@@ -314,13 +383,14 @@ def create_namespaced_job_with_http_info(self, namespace, body, **kwargs): # no
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Job', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_namespaced_cron_job(self, namespace, **kwargs): # noqa: E501
"""delete_collection_namespaced_cron_job # noqa: E501
@@ -328,36 +398,56 @@ def delete_collection_namespaced_cron_job(self, namespace, **kwargs): # noqa: E
delete collection of CronJob # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_cron_job(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_namespaced_cron_job_with_http_info(namespace, **kwargs) # noqa: E501
@@ -368,38 +458,64 @@ def delete_collection_namespaced_cron_job_with_http_info(self, namespace, **kwar
delete collection of CronJob # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_cron_job_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -427,7 +543,10 @@ def delete_collection_namespaced_cron_job_with_http_info(self, namespace, **kwar
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -440,8 +559,7 @@ def delete_collection_namespaced_cron_job_with_http_info(self, namespace, **kwar
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_cron_job`") # noqa: E501
collection_formats = {}
@@ -451,36 +569,36 @@ def delete_collection_namespaced_cron_job_with_http_info(self, namespace, **kwar
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -495,6 +613,11 @@ def delete_collection_namespaced_cron_job_with_http_info(self, namespace, **kwar
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/batch/v1/namespaces/{namespace}/cronjobs', 'DELETE',
path_params,
@@ -503,13 +626,14 @@ def delete_collection_namespaced_cron_job_with_http_info(self, namespace, **kwar
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_namespaced_job(self, namespace, **kwargs): # noqa: E501
"""delete_collection_namespaced_job # noqa: E501
@@ -517,36 +641,56 @@ def delete_collection_namespaced_job(self, namespace, **kwargs): # noqa: E501
delete collection of Job # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_job(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_namespaced_job_with_http_info(namespace, **kwargs) # noqa: E501
@@ -557,38 +701,64 @@ def delete_collection_namespaced_job_with_http_info(self, namespace, **kwargs):
delete collection of Job # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_job_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -616,7 +786,10 @@ def delete_collection_namespaced_job_with_http_info(self, namespace, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -629,8 +802,7 @@ def delete_collection_namespaced_job_with_http_info(self, namespace, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_job`") # noqa: E501
collection_formats = {}
@@ -640,36 +812,36 @@ def delete_collection_namespaced_job_with_http_info(self, namespace, **kwargs):
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -684,6 +856,11 @@ def delete_collection_namespaced_job_with_http_info(self, namespace, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/batch/v1/namespaces/{namespace}/jobs', 'DELETE',
path_params,
@@ -692,13 +869,14 @@ def delete_collection_namespaced_job_with_http_info(self, namespace, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_namespaced_cron_job(self, name, namespace, **kwargs): # noqa: E501
"""delete_namespaced_cron_job # noqa: E501
@@ -706,29 +884,42 @@ def delete_namespaced_cron_job(self, name, namespace, **kwargs): # noqa: E501
delete a CronJob # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_cron_job(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CronJob (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the CronJob (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_namespaced_cron_job_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -739,31 +930,50 @@ def delete_namespaced_cron_job_with_http_info(self, name, namespace, **kwargs):
delete a CronJob # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_cron_job_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CronJob (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the CronJob (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -784,7 +994,10 @@ def delete_namespaced_cron_job_with_http_info(self, name, namespace, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -797,12 +1010,10 @@ def delete_namespaced_cron_job_with_http_info(self, name, namespace, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_cron_job`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_cron_job`") # noqa: E501
collection_formats = {}
@@ -814,20 +1025,20 @@ def delete_namespaced_cron_job_with_http_info(self, name, namespace, **kwargs):
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -842,6 +1053,12 @@ def delete_namespaced_cron_job_with_http_info(self, name, namespace, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/batch/v1/namespaces/{namespace}/cronjobs/{name}', 'DELETE',
path_params,
@@ -850,13 +1067,14 @@ def delete_namespaced_cron_job_with_http_info(self, name, namespace, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_namespaced_job(self, name, namespace, **kwargs): # noqa: E501
"""delete_namespaced_job # noqa: E501
@@ -864,29 +1082,42 @@ def delete_namespaced_job(self, name, namespace, **kwargs): # noqa: E501
delete a Job # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_job(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Job (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the Job (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_namespaced_job_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -897,31 +1128,50 @@ def delete_namespaced_job_with_http_info(self, name, namespace, **kwargs): # no
delete a Job # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_job_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Job (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the Job (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -942,7 +1192,10 @@ def delete_namespaced_job_with_http_info(self, name, namespace, **kwargs): # no
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -955,12 +1208,10 @@ def delete_namespaced_job_with_http_info(self, name, namespace, **kwargs): # no
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_job`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_job`") # noqa: E501
collection_formats = {}
@@ -972,20 +1223,20 @@ def delete_namespaced_job_with_http_info(self, name, namespace, **kwargs): # no
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1000,6 +1251,12 @@ def delete_namespaced_job_with_http_info(self, name, namespace, **kwargs): # no
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/batch/v1/namespaces/{namespace}/jobs/{name}', 'DELETE',
path_params,
@@ -1008,13 +1265,14 @@ def delete_namespaced_job_with_http_info(self, name, namespace, **kwargs): # no
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def get_api_resources(self, **kwargs): # noqa: E501
"""get_api_resources # noqa: E501
@@ -1022,20 +1280,24 @@ def get_api_resources(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIResourceList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIResourceList
"""
kwargs['_return_http_data_only'] = True
return self.get_api_resources_with_http_info(**kwargs) # noqa: E501
@@ -1046,22 +1308,32 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1073,7 +1345,10 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1092,7 +1367,7 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1105,6 +1380,11 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIResourceList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/batch/v1/', 'GET',
path_params,
@@ -1113,13 +1393,14 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIResourceList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_cron_job_for_all_namespaces(self, **kwargs): # noqa: E501
"""list_cron_job_for_all_namespaces # noqa: E501
@@ -1127,31 +1408,46 @@ def list_cron_job_for_all_namespaces(self, **kwargs): # noqa: E501
list or watch objects of kind CronJob # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_cron_job_for_all_namespaces(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1CronJobList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1CronJobList
"""
kwargs['_return_http_data_only'] = True
return self.list_cron_job_for_all_namespaces_with_http_info(**kwargs) # noqa: E501
@@ -1162,33 +1458,54 @@ def list_cron_job_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E5
list or watch objects of kind CronJob # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_cron_job_for_all_namespaces_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1CronJobList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1CronJobList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1211,7 +1528,10 @@ def list_cron_job_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E5
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1229,30 +1549,30 @@ def list_cron_job_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E5
path_params = {}
query_params = []
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1265,6 +1585,11 @@ def list_cron_job_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E5
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1CronJobList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/batch/v1/cronjobs', 'GET',
path_params,
@@ -1273,13 +1598,14 @@ def list_cron_job_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E5
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1CronJobList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_job_for_all_namespaces(self, **kwargs): # noqa: E501
"""list_job_for_all_namespaces # noqa: E501
@@ -1287,31 +1613,46 @@ def list_job_for_all_namespaces(self, **kwargs): # noqa: E501
list or watch objects of kind Job # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_job_for_all_namespaces(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1JobList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1JobList
"""
kwargs['_return_http_data_only'] = True
return self.list_job_for_all_namespaces_with_http_info(**kwargs) # noqa: E501
@@ -1322,33 +1663,54 @@ def list_job_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501
list or watch objects of kind Job # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_job_for_all_namespaces_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1JobList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1JobList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1371,7 +1733,10 @@ def list_job_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1389,30 +1754,30 @@ def list_job_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501
path_params = {}
query_params = []
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1425,6 +1790,11 @@ def list_job_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1JobList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/batch/v1/jobs', 'GET',
path_params,
@@ -1433,13 +1803,14 @@ def list_job_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1JobList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_namespaced_cron_job(self, namespace, **kwargs): # noqa: E501
"""list_namespaced_cron_job # noqa: E501
@@ -1447,32 +1818,48 @@ def list_namespaced_cron_job(self, namespace, **kwargs): # noqa: E501
list or watch objects of kind CronJob # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_cron_job(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1CronJobList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1CronJobList
"""
kwargs['_return_http_data_only'] = True
return self.list_namespaced_cron_job_with_http_info(namespace, **kwargs) # noqa: E501
@@ -1483,34 +1870,56 @@ def list_namespaced_cron_job_with_http_info(self, namespace, **kwargs): # noqa:
list or watch objects of kind CronJob # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_cron_job_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1CronJobList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1CronJobList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1534,7 +1943,10 @@ def list_namespaced_cron_job_with_http_info(self, namespace, **kwargs): # noqa:
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1547,8 +1959,7 @@ def list_namespaced_cron_job_with_http_info(self, namespace, **kwargs): # noqa:
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_cron_job`") # noqa: E501
collection_formats = {}
@@ -1558,30 +1969,30 @@ def list_namespaced_cron_job_with_http_info(self, namespace, **kwargs): # noqa:
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1594,6 +2005,11 @@ def list_namespaced_cron_job_with_http_info(self, namespace, **kwargs): # noqa:
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1CronJobList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/batch/v1/namespaces/{namespace}/cronjobs', 'GET',
path_params,
@@ -1602,13 +2018,14 @@ def list_namespaced_cron_job_with_http_info(self, namespace, **kwargs): # noqa:
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1CronJobList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_namespaced_job(self, namespace, **kwargs): # noqa: E501
"""list_namespaced_job # noqa: E501
@@ -1616,32 +2033,48 @@ def list_namespaced_job(self, namespace, **kwargs): # noqa: E501
list or watch objects of kind Job # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_job(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1JobList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1JobList
"""
kwargs['_return_http_data_only'] = True
return self.list_namespaced_job_with_http_info(namespace, **kwargs) # noqa: E501
@@ -1652,34 +2085,56 @@ def list_namespaced_job_with_http_info(self, namespace, **kwargs): # noqa: E501
list or watch objects of kind Job # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_job_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1JobList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1JobList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1703,7 +2158,10 @@ def list_namespaced_job_with_http_info(self, namespace, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1716,8 +2174,7 @@ def list_namespaced_job_with_http_info(self, namespace, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_job`") # noqa: E501
collection_formats = {}
@@ -1727,30 +2184,30 @@ def list_namespaced_job_with_http_info(self, namespace, **kwargs): # noqa: E501
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1763,6 +2220,11 @@ def list_namespaced_job_with_http_info(self, namespace, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1JobList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/batch/v1/namespaces/{namespace}/jobs', 'GET',
path_params,
@@ -1771,13 +2233,14 @@ def list_namespaced_job_with_http_info(self, namespace, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1JobList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_cron_job(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_cron_job # noqa: E501
@@ -1785,28 +2248,40 @@ def patch_namespaced_cron_job(self, name, namespace, body, **kwargs): # noqa: E
partially update the specified CronJob # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_cron_job(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CronJob (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the CronJob (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1CronJob
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1CronJob
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_cron_job_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -1817,30 +2292,48 @@ def patch_namespaced_cron_job_with_http_info(self, name, namespace, body, **kwar
partially update the specified CronJob # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_cron_job_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CronJob (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the CronJob (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1CronJob, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1CronJob, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1860,7 +2353,10 @@ def patch_namespaced_cron_job_with_http_info(self, name, namespace, body, **kwar
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1873,16 +2369,13 @@ def patch_namespaced_cron_job_with_http_info(self, name, namespace, body, **kwar
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_cron_job`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_cron_job`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_cron_job`") # noqa: E501
collection_formats = {}
@@ -1894,18 +2387,18 @@ def patch_namespaced_cron_job_with_http_info(self, name, namespace, body, **kwar
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1918,12 +2411,22 @@ def patch_namespaced_cron_job_with_http_info(self, name, namespace, body, **kwar
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1CronJob",
+ 201: "V1CronJob",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/batch/v1/namespaces/{namespace}/cronjobs/{name}', 'PATCH',
path_params,
@@ -1932,13 +2435,14 @@ def patch_namespaced_cron_job_with_http_info(self, name, namespace, body, **kwar
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1CronJob', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_cron_job_status(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_cron_job_status # noqa: E501
@@ -1946,28 +2450,40 @@ def patch_namespaced_cron_job_status(self, name, namespace, body, **kwargs): #
partially update status of the specified CronJob # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_cron_job_status(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CronJob (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the CronJob (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1CronJob
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1CronJob
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_cron_job_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -1978,30 +2494,48 @@ def patch_namespaced_cron_job_status_with_http_info(self, name, namespace, body,
partially update status of the specified CronJob # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_cron_job_status_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CronJob (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the CronJob (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1CronJob, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1CronJob, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2021,7 +2555,10 @@ def patch_namespaced_cron_job_status_with_http_info(self, name, namespace, body,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2034,16 +2571,13 @@ def patch_namespaced_cron_job_status_with_http_info(self, name, namespace, body,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_cron_job_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_cron_job_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_cron_job_status`") # noqa: E501
collection_formats = {}
@@ -2055,18 +2589,18 @@ def patch_namespaced_cron_job_status_with_http_info(self, name, namespace, body,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2079,12 +2613,22 @@ def patch_namespaced_cron_job_status_with_http_info(self, name, namespace, body,
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1CronJob",
+ 201: "V1CronJob",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/batch/v1/namespaces/{namespace}/cronjobs/{name}/status', 'PATCH',
path_params,
@@ -2093,13 +2637,14 @@ def patch_namespaced_cron_job_status_with_http_info(self, name, namespace, body,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1CronJob', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_job(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_job # noqa: E501
@@ -2107,28 +2652,40 @@ def patch_namespaced_job(self, name, namespace, body, **kwargs): # noqa: E501
partially update the specified Job # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_job(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Job (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Job (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Job
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Job
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_job_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -2139,30 +2696,48 @@ def patch_namespaced_job_with_http_info(self, name, namespace, body, **kwargs):
partially update the specified Job # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_job_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Job (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Job (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Job, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Job, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2182,7 +2757,10 @@ def patch_namespaced_job_with_http_info(self, name, namespace, body, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2195,16 +2773,13 @@ def patch_namespaced_job_with_http_info(self, name, namespace, body, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_job`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_job`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_job`") # noqa: E501
collection_formats = {}
@@ -2216,18 +2791,18 @@ def patch_namespaced_job_with_http_info(self, name, namespace, body, **kwargs):
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2240,12 +2815,22 @@ def patch_namespaced_job_with_http_info(self, name, namespace, body, **kwargs):
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Job",
+ 201: "V1Job",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/batch/v1/namespaces/{namespace}/jobs/{name}', 'PATCH',
path_params,
@@ -2254,13 +2839,14 @@ def patch_namespaced_job_with_http_info(self, name, namespace, body, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Job', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_job_status(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_job_status # noqa: E501
@@ -2268,28 +2854,40 @@ def patch_namespaced_job_status(self, name, namespace, body, **kwargs): # noqa:
partially update status of the specified Job # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_job_status(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Job (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Job (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Job
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Job
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_job_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -2300,30 +2898,48 @@ def patch_namespaced_job_status_with_http_info(self, name, namespace, body, **kw
partially update status of the specified Job # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_job_status_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Job (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Job (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Job, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Job, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2343,7 +2959,10 @@ def patch_namespaced_job_status_with_http_info(self, name, namespace, body, **kw
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2356,16 +2975,13 @@ def patch_namespaced_job_status_with_http_info(self, name, namespace, body, **kw
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_job_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_job_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_job_status`") # noqa: E501
collection_formats = {}
@@ -2377,18 +2993,18 @@ def patch_namespaced_job_status_with_http_info(self, name, namespace, body, **kw
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2401,12 +3017,22 @@ def patch_namespaced_job_status_with_http_info(self, name, namespace, body, **kw
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Job",
+ 201: "V1Job",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/batch/v1/namespaces/{namespace}/jobs/{name}/status', 'PATCH',
path_params,
@@ -2415,13 +3041,14 @@ def patch_namespaced_job_status_with_http_info(self, name, namespace, body, **kw
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Job', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_cron_job(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_cron_job # noqa: E501
@@ -2429,23 +3056,30 @@ def read_namespaced_cron_job(self, name, namespace, **kwargs): # noqa: E501
read the specified CronJob # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_cron_job(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CronJob (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the CronJob (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1CronJob
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1CronJob
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_cron_job_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -2456,25 +3090,38 @@ def read_namespaced_cron_job_with_http_info(self, name, namespace, **kwargs): #
read the specified CronJob # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_cron_job_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CronJob (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the CronJob (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1CronJob, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1CronJob, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2489,7 +3136,10 @@ def read_namespaced_cron_job_with_http_info(self, name, namespace, **kwargs): #
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2502,12 +3152,10 @@ def read_namespaced_cron_job_with_http_info(self, name, namespace, **kwargs): #
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_cron_job`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_cron_job`") # noqa: E501
collection_formats = {}
@@ -2519,10 +3167,10 @@ def read_namespaced_cron_job_with_http_info(self, name, namespace, **kwargs): #
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2535,6 +3183,11 @@ def read_namespaced_cron_job_with_http_info(self, name, namespace, **kwargs): #
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1CronJob",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/batch/v1/namespaces/{namespace}/cronjobs/{name}', 'GET',
path_params,
@@ -2543,13 +3196,14 @@ def read_namespaced_cron_job_with_http_info(self, name, namespace, **kwargs): #
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1CronJob', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_cron_job_status(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_cron_job_status # noqa: E501
@@ -2557,23 +3211,30 @@ def read_namespaced_cron_job_status(self, name, namespace, **kwargs): # noqa: E
read status of the specified CronJob # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_cron_job_status(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CronJob (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the CronJob (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1CronJob
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1CronJob
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_cron_job_status_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -2584,25 +3245,38 @@ def read_namespaced_cron_job_status_with_http_info(self, name, namespace, **kwar
read status of the specified CronJob # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_cron_job_status_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CronJob (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the CronJob (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1CronJob, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1CronJob, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2617,7 +3291,10 @@ def read_namespaced_cron_job_status_with_http_info(self, name, namespace, **kwar
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2630,12 +3307,10 @@ def read_namespaced_cron_job_status_with_http_info(self, name, namespace, **kwar
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_cron_job_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_cron_job_status`") # noqa: E501
collection_formats = {}
@@ -2647,10 +3322,10 @@ def read_namespaced_cron_job_status_with_http_info(self, name, namespace, **kwar
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2663,6 +3338,11 @@ def read_namespaced_cron_job_status_with_http_info(self, name, namespace, **kwar
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1CronJob",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/batch/v1/namespaces/{namespace}/cronjobs/{name}/status', 'GET',
path_params,
@@ -2671,13 +3351,14 @@ def read_namespaced_cron_job_status_with_http_info(self, name, namespace, **kwar
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1CronJob', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_job(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_job # noqa: E501
@@ -2685,23 +3366,30 @@ def read_namespaced_job(self, name, namespace, **kwargs): # noqa: E501
read the specified Job # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_job(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Job (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Job (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Job
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Job
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_job_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -2712,25 +3400,38 @@ def read_namespaced_job_with_http_info(self, name, namespace, **kwargs): # noqa
read the specified Job # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_job_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Job (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Job (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Job, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Job, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2745,7 +3446,10 @@ def read_namespaced_job_with_http_info(self, name, namespace, **kwargs): # noqa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2758,12 +3462,10 @@ def read_namespaced_job_with_http_info(self, name, namespace, **kwargs): # noqa
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_job`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_job`") # noqa: E501
collection_formats = {}
@@ -2775,10 +3477,10 @@ def read_namespaced_job_with_http_info(self, name, namespace, **kwargs): # noqa
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2791,6 +3493,11 @@ def read_namespaced_job_with_http_info(self, name, namespace, **kwargs): # noqa
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Job",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/batch/v1/namespaces/{namespace}/jobs/{name}', 'GET',
path_params,
@@ -2799,13 +3506,14 @@ def read_namespaced_job_with_http_info(self, name, namespace, **kwargs): # noqa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Job', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_job_status(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_job_status # noqa: E501
@@ -2813,23 +3521,30 @@ def read_namespaced_job_status(self, name, namespace, **kwargs): # noqa: E501
read status of the specified Job # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_job_status(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Job (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Job (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Job
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Job
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_job_status_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -2840,25 +3555,38 @@ def read_namespaced_job_status_with_http_info(self, name, namespace, **kwargs):
read status of the specified Job # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_job_status_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Job (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Job (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Job, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Job, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2873,7 +3601,10 @@ def read_namespaced_job_status_with_http_info(self, name, namespace, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2886,12 +3617,10 @@ def read_namespaced_job_status_with_http_info(self, name, namespace, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_job_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_job_status`") # noqa: E501
collection_formats = {}
@@ -2903,10 +3632,10 @@ def read_namespaced_job_status_with_http_info(self, name, namespace, **kwargs):
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2919,6 +3648,11 @@ def read_namespaced_job_status_with_http_info(self, name, namespace, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Job",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/batch/v1/namespaces/{namespace}/jobs/{name}/status', 'GET',
path_params,
@@ -2927,13 +3661,14 @@ def read_namespaced_job_status_with_http_info(self, name, namespace, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Job', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_cron_job(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_cron_job # noqa: E501
@@ -2941,27 +3676,38 @@ def replace_namespaced_cron_job(self, name, namespace, body, **kwargs): # noqa:
replace the specified CronJob # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_cron_job(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CronJob (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1CronJob body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the CronJob (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1CronJob
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1CronJob
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1CronJob
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_cron_job_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -2972,29 +3718,46 @@ def replace_namespaced_cron_job_with_http_info(self, name, namespace, body, **kw
replace the specified CronJob # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_cron_job_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CronJob (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1CronJob body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the CronJob (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1CronJob
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1CronJob, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1CronJob, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3013,7 +3776,10 @@ def replace_namespaced_cron_job_with_http_info(self, name, namespace, body, **kw
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3026,16 +3792,13 @@ def replace_namespaced_cron_job_with_http_info(self, name, namespace, body, **kw
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_cron_job`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_cron_job`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_cron_job`") # noqa: E501
collection_formats = {}
@@ -3047,16 +3810,16 @@ def replace_namespaced_cron_job_with_http_info(self, name, namespace, body, **kw
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3071,6 +3834,12 @@ def replace_namespaced_cron_job_with_http_info(self, name, namespace, body, **kw
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1CronJob",
+ 201: "V1CronJob",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/batch/v1/namespaces/{namespace}/cronjobs/{name}', 'PUT',
path_params,
@@ -3079,13 +3848,14 @@ def replace_namespaced_cron_job_with_http_info(self, name, namespace, body, **kw
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1CronJob', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_cron_job_status(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_cron_job_status # noqa: E501
@@ -3093,27 +3863,38 @@ def replace_namespaced_cron_job_status(self, name, namespace, body, **kwargs):
replace status of the specified CronJob # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_cron_job_status(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CronJob (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1CronJob body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the CronJob (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1CronJob
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1CronJob
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1CronJob
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_cron_job_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -3124,29 +3905,46 @@ def replace_namespaced_cron_job_status_with_http_info(self, name, namespace, bod
replace status of the specified CronJob # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_cron_job_status_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CronJob (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1CronJob body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the CronJob (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1CronJob
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1CronJob, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1CronJob, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3165,7 +3963,10 @@ def replace_namespaced_cron_job_status_with_http_info(self, name, namespace, bod
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3178,16 +3979,13 @@ def replace_namespaced_cron_job_status_with_http_info(self, name, namespace, bod
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_cron_job_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_cron_job_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_cron_job_status`") # noqa: E501
collection_formats = {}
@@ -3199,16 +3997,16 @@ def replace_namespaced_cron_job_status_with_http_info(self, name, namespace, bod
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3223,6 +4021,12 @@ def replace_namespaced_cron_job_status_with_http_info(self, name, namespace, bod
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1CronJob",
+ 201: "V1CronJob",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/batch/v1/namespaces/{namespace}/cronjobs/{name}/status', 'PUT',
path_params,
@@ -3231,13 +4035,14 @@ def replace_namespaced_cron_job_status_with_http_info(self, name, namespace, bod
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1CronJob', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_job(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_job # noqa: E501
@@ -3245,27 +4050,38 @@ def replace_namespaced_job(self, name, namespace, body, **kwargs): # noqa: E501
replace the specified Job # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_job(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Job (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Job body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Job (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Job
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Job
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Job
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_job_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -3276,29 +4092,46 @@ def replace_namespaced_job_with_http_info(self, name, namespace, body, **kwargs)
replace the specified Job # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_job_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Job (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Job body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Job (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Job
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Job, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Job, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3317,7 +4150,10 @@ def replace_namespaced_job_with_http_info(self, name, namespace, body, **kwargs)
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3330,16 +4166,13 @@ def replace_namespaced_job_with_http_info(self, name, namespace, body, **kwargs)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_job`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_job`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_job`") # noqa: E501
collection_formats = {}
@@ -3351,16 +4184,16 @@ def replace_namespaced_job_with_http_info(self, name, namespace, body, **kwargs)
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3375,6 +4208,12 @@ def replace_namespaced_job_with_http_info(self, name, namespace, body, **kwargs)
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Job",
+ 201: "V1Job",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/batch/v1/namespaces/{namespace}/jobs/{name}', 'PUT',
path_params,
@@ -3383,13 +4222,14 @@ def replace_namespaced_job_with_http_info(self, name, namespace, body, **kwargs)
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Job', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_job_status(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_job_status # noqa: E501
@@ -3397,27 +4237,38 @@ def replace_namespaced_job_status(self, name, namespace, body, **kwargs): # noq
replace status of the specified Job # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_job_status(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Job (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Job body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Job (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Job
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Job
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Job
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_job_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -3428,29 +4279,46 @@ def replace_namespaced_job_status_with_http_info(self, name, namespace, body, **
replace status of the specified Job # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_job_status_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Job (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Job body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Job (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Job
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Job, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Job, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3469,7 +4337,10 @@ def replace_namespaced_job_status_with_http_info(self, name, namespace, body, **
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3482,16 +4353,13 @@ def replace_namespaced_job_status_with_http_info(self, name, namespace, body, **
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_job_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_job_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_job_status`") # noqa: E501
collection_formats = {}
@@ -3503,16 +4371,16 @@ def replace_namespaced_job_status_with_http_info(self, name, namespace, body, **
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3527,6 +4395,12 @@ def replace_namespaced_job_status_with_http_info(self, name, namespace, body, **
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Job",
+ 201: "V1Job",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/batch/v1/namespaces/{namespace}/jobs/{name}/status', 'PUT',
path_params,
@@ -3535,10 +4409,11 @@ def replace_namespaced_job_status_with_http_info(self, name, namespace, body, **
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Job', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/certificates_api.py b/kubernetes/client/api/certificates_api.py
index a47bc5a92a..4dfa15eb3c 100644
--- a/kubernetes/client/api/certificates_api.py
+++ b/kubernetes/client/api/certificates_api.py
@@ -42,20 +42,24 @@ def get_api_group(self, **kwargs): # noqa: E501
get information of a group # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_group(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIGroup
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIGroup
"""
kwargs['_return_http_data_only'] = True
return self.get_api_group_with_http_info(**kwargs) # noqa: E501
@@ -66,22 +70,32 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
get information of a group # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_group_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIGroup, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIGroup, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -93,7 +107,10 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -112,7 +129,7 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -125,6 +142,11 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIGroup",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/', 'GET',
path_params,
@@ -133,10 +155,11 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIGroup', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/certificates_v1_api.py b/kubernetes/client/api/certificates_v1_api.py
index 55c1de776f..4c35c72c80 100644
--- a/kubernetes/client/api/certificates_v1_api.py
+++ b/kubernetes/client/api/certificates_v1_api.py
@@ -42,25 +42,34 @@ def create_certificate_signing_request(self, body, **kwargs): # noqa: E501
create a CertificateSigningRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_certificate_signing_request(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1CertificateSigningRequest body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1CertificateSigningRequest
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1CertificateSigningRequest
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1CertificateSigningRequest
"""
kwargs['_return_http_data_only'] = True
return self.create_certificate_signing_request_with_http_info(body, **kwargs) # noqa: E501
@@ -71,27 +80,42 @@ def create_certificate_signing_request_with_http_info(self, body, **kwargs): #
create a CertificateSigningRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_certificate_signing_request_with_http_info(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1CertificateSigningRequest body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1CertificateSigningRequest
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1CertificateSigningRequest, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1CertificateSigningRequest, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -108,7 +132,10 @@ def create_certificate_signing_request_with_http_info(self, body, **kwargs): #
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -121,8 +148,7 @@ def create_certificate_signing_request_with_http_info(self, body, **kwargs): #
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_certificate_signing_request`") # noqa: E501
collection_formats = {}
@@ -130,16 +156,16 @@ def create_certificate_signing_request_with_http_info(self, body, **kwargs): #
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -154,6 +180,13 @@ def create_certificate_signing_request_with_http_info(self, body, **kwargs): #
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1CertificateSigningRequest",
+ 201: "V1CertificateSigningRequest",
+ 202: "V1CertificateSigningRequest",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1/certificatesigningrequests', 'POST',
path_params,
@@ -162,13 +195,14 @@ def create_certificate_signing_request_with_http_info(self, body, **kwargs): #
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1CertificateSigningRequest', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_certificate_signing_request(self, name, **kwargs): # noqa: E501
"""delete_certificate_signing_request # noqa: E501
@@ -176,28 +210,40 @@ def delete_certificate_signing_request(self, name, **kwargs): # noqa: E501
delete a CertificateSigningRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_certificate_signing_request(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CertificateSigningRequest (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the CertificateSigningRequest (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_certificate_signing_request_with_http_info(name, **kwargs) # noqa: E501
@@ -208,30 +254,48 @@ def delete_certificate_signing_request_with_http_info(self, name, **kwargs): #
delete a CertificateSigningRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_certificate_signing_request_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CertificateSigningRequest (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the CertificateSigningRequest (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -251,7 +315,10 @@ def delete_certificate_signing_request_with_http_info(self, name, **kwargs): #
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -264,8 +331,7 @@ def delete_certificate_signing_request_with_http_info(self, name, **kwargs): #
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_certificate_signing_request`") # noqa: E501
collection_formats = {}
@@ -275,20 +341,20 @@ def delete_certificate_signing_request_with_http_info(self, name, **kwargs): #
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -303,6 +369,12 @@ def delete_certificate_signing_request_with_http_info(self, name, **kwargs): #
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1/certificatesigningrequests/{name}', 'DELETE',
path_params,
@@ -311,13 +383,14 @@ def delete_certificate_signing_request_with_http_info(self, name, **kwargs): #
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_certificate_signing_request(self, **kwargs): # noqa: E501
"""delete_collection_certificate_signing_request # noqa: E501
@@ -325,35 +398,54 @@ def delete_collection_certificate_signing_request(self, **kwargs): # noqa: E501
delete collection of CertificateSigningRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_certificate_signing_request(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_certificate_signing_request_with_http_info(**kwargs) # noqa: E501
@@ -364,37 +456,62 @@ def delete_collection_certificate_signing_request_with_http_info(self, **kwargs)
delete collection of CertificateSigningRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_certificate_signing_request_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -421,7 +538,10 @@ def delete_collection_certificate_signing_request_with_http_info(self, **kwargs)
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -439,36 +559,36 @@ def delete_collection_certificate_signing_request_with_http_info(self, **kwargs)
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -483,6 +603,11 @@ def delete_collection_certificate_signing_request_with_http_info(self, **kwargs)
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1/certificatesigningrequests', 'DELETE',
path_params,
@@ -491,13 +616,14 @@ def delete_collection_certificate_signing_request_with_http_info(self, **kwargs)
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def get_api_resources(self, **kwargs): # noqa: E501
"""get_api_resources # noqa: E501
@@ -505,20 +631,24 @@ def get_api_resources(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIResourceList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIResourceList
"""
kwargs['_return_http_data_only'] = True
return self.get_api_resources_with_http_info(**kwargs) # noqa: E501
@@ -529,22 +659,32 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -556,7 +696,10 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -575,7 +718,7 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -588,6 +731,11 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIResourceList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1/', 'GET',
path_params,
@@ -596,13 +744,14 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIResourceList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_certificate_signing_request(self, **kwargs): # noqa: E501
"""list_certificate_signing_request # noqa: E501
@@ -610,31 +759,46 @@ def list_certificate_signing_request(self, **kwargs): # noqa: E501
list or watch objects of kind CertificateSigningRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_certificate_signing_request(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1CertificateSigningRequestList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1CertificateSigningRequestList
"""
kwargs['_return_http_data_only'] = True
return self.list_certificate_signing_request_with_http_info(**kwargs) # noqa: E501
@@ -645,33 +809,54 @@ def list_certificate_signing_request_with_http_info(self, **kwargs): # noqa: E5
list or watch objects of kind CertificateSigningRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_certificate_signing_request_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1CertificateSigningRequestList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1CertificateSigningRequestList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -694,7 +879,10 @@ def list_certificate_signing_request_with_http_info(self, **kwargs): # noqa: E5
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -712,30 +900,30 @@ def list_certificate_signing_request_with_http_info(self, **kwargs): # noqa: E5
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -748,6 +936,11 @@ def list_certificate_signing_request_with_http_info(self, **kwargs): # noqa: E5
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1CertificateSigningRequestList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1/certificatesigningrequests', 'GET',
path_params,
@@ -756,13 +949,14 @@ def list_certificate_signing_request_with_http_info(self, **kwargs): # noqa: E5
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1CertificateSigningRequestList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_certificate_signing_request(self, name, body, **kwargs): # noqa: E501
"""patch_certificate_signing_request # noqa: E501
@@ -770,27 +964,38 @@ def patch_certificate_signing_request(self, name, body, **kwargs): # noqa: E501
partially update the specified CertificateSigningRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_certificate_signing_request(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CertificateSigningRequest (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the CertificateSigningRequest (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1CertificateSigningRequest
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1CertificateSigningRequest
"""
kwargs['_return_http_data_only'] = True
return self.patch_certificate_signing_request_with_http_info(name, body, **kwargs) # noqa: E501
@@ -801,29 +1006,46 @@ def patch_certificate_signing_request_with_http_info(self, name, body, **kwargs)
partially update the specified CertificateSigningRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_certificate_signing_request_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CertificateSigningRequest (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the CertificateSigningRequest (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1CertificateSigningRequest, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1CertificateSigningRequest, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -842,7 +1064,10 @@ def patch_certificate_signing_request_with_http_info(self, name, body, **kwargs)
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -855,12 +1080,10 @@ def patch_certificate_signing_request_with_http_info(self, name, body, **kwargs)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_certificate_signing_request`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_certificate_signing_request`") # noqa: E501
collection_formats = {}
@@ -870,18 +1093,18 @@ def patch_certificate_signing_request_with_http_info(self, name, body, **kwargs)
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -894,12 +1117,22 @@ def patch_certificate_signing_request_with_http_info(self, name, body, **kwargs)
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1CertificateSigningRequest",
+ 201: "V1CertificateSigningRequest",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1/certificatesigningrequests/{name}', 'PATCH',
path_params,
@@ -908,13 +1141,14 @@ def patch_certificate_signing_request_with_http_info(self, name, body, **kwargs)
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1CertificateSigningRequest', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_certificate_signing_request_approval(self, name, body, **kwargs): # noqa: E501
"""patch_certificate_signing_request_approval # noqa: E501
@@ -922,27 +1156,38 @@ def patch_certificate_signing_request_approval(self, name, body, **kwargs): # n
partially update approval of the specified CertificateSigningRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_certificate_signing_request_approval(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CertificateSigningRequest (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the CertificateSigningRequest (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1CertificateSigningRequest
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1CertificateSigningRequest
"""
kwargs['_return_http_data_only'] = True
return self.patch_certificate_signing_request_approval_with_http_info(name, body, **kwargs) # noqa: E501
@@ -953,29 +1198,46 @@ def patch_certificate_signing_request_approval_with_http_info(self, name, body,
partially update approval of the specified CertificateSigningRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_certificate_signing_request_approval_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CertificateSigningRequest (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the CertificateSigningRequest (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1CertificateSigningRequest, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1CertificateSigningRequest, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -994,7 +1256,10 @@ def patch_certificate_signing_request_approval_with_http_info(self, name, body,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1007,12 +1272,10 @@ def patch_certificate_signing_request_approval_with_http_info(self, name, body,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_certificate_signing_request_approval`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_certificate_signing_request_approval`") # noqa: E501
collection_formats = {}
@@ -1022,18 +1285,18 @@ def patch_certificate_signing_request_approval_with_http_info(self, name, body,
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1046,12 +1309,22 @@ def patch_certificate_signing_request_approval_with_http_info(self, name, body,
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1CertificateSigningRequest",
+ 201: "V1CertificateSigningRequest",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1/certificatesigningrequests/{name}/approval', 'PATCH',
path_params,
@@ -1060,13 +1333,14 @@ def patch_certificate_signing_request_approval_with_http_info(self, name, body,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1CertificateSigningRequest', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_certificate_signing_request_status(self, name, body, **kwargs): # noqa: E501
"""patch_certificate_signing_request_status # noqa: E501
@@ -1074,27 +1348,38 @@ def patch_certificate_signing_request_status(self, name, body, **kwargs): # noq
partially update status of the specified CertificateSigningRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_certificate_signing_request_status(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CertificateSigningRequest (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the CertificateSigningRequest (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1CertificateSigningRequest
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1CertificateSigningRequest
"""
kwargs['_return_http_data_only'] = True
return self.patch_certificate_signing_request_status_with_http_info(name, body, **kwargs) # noqa: E501
@@ -1105,29 +1390,46 @@ def patch_certificate_signing_request_status_with_http_info(self, name, body, **
partially update status of the specified CertificateSigningRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_certificate_signing_request_status_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CertificateSigningRequest (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the CertificateSigningRequest (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1CertificateSigningRequest, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1CertificateSigningRequest, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1146,7 +1448,10 @@ def patch_certificate_signing_request_status_with_http_info(self, name, body, **
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1159,12 +1464,10 @@ def patch_certificate_signing_request_status_with_http_info(self, name, body, **
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_certificate_signing_request_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_certificate_signing_request_status`") # noqa: E501
collection_formats = {}
@@ -1174,18 +1477,18 @@ def patch_certificate_signing_request_status_with_http_info(self, name, body, **
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1198,12 +1501,22 @@ def patch_certificate_signing_request_status_with_http_info(self, name, body, **
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1CertificateSigningRequest",
+ 201: "V1CertificateSigningRequest",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1/certificatesigningrequests/{name}/status', 'PATCH',
path_params,
@@ -1212,13 +1525,14 @@ def patch_certificate_signing_request_status_with_http_info(self, name, body, **
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1CertificateSigningRequest', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_certificate_signing_request(self, name, **kwargs): # noqa: E501
"""read_certificate_signing_request # noqa: E501
@@ -1226,22 +1540,28 @@ def read_certificate_signing_request(self, name, **kwargs): # noqa: E501
read the specified CertificateSigningRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_certificate_signing_request(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CertificateSigningRequest (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the CertificateSigningRequest (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1CertificateSigningRequest
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1CertificateSigningRequest
"""
kwargs['_return_http_data_only'] = True
return self.read_certificate_signing_request_with_http_info(name, **kwargs) # noqa: E501
@@ -1252,24 +1572,36 @@ def read_certificate_signing_request_with_http_info(self, name, **kwargs): # no
read the specified CertificateSigningRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_certificate_signing_request_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CertificateSigningRequest (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the CertificateSigningRequest (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1CertificateSigningRequest, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1CertificateSigningRequest, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1283,7 +1615,10 @@ def read_certificate_signing_request_with_http_info(self, name, **kwargs): # no
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1296,8 +1631,7 @@ def read_certificate_signing_request_with_http_info(self, name, **kwargs): # no
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_certificate_signing_request`") # noqa: E501
collection_formats = {}
@@ -1307,10 +1641,10 @@ def read_certificate_signing_request_with_http_info(self, name, **kwargs): # no
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1323,6 +1657,11 @@ def read_certificate_signing_request_with_http_info(self, name, **kwargs): # no
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1CertificateSigningRequest",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1/certificatesigningrequests/{name}', 'GET',
path_params,
@@ -1331,13 +1670,14 @@ def read_certificate_signing_request_with_http_info(self, name, **kwargs): # no
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1CertificateSigningRequest', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_certificate_signing_request_approval(self, name, **kwargs): # noqa: E501
"""read_certificate_signing_request_approval # noqa: E501
@@ -1345,22 +1685,28 @@ def read_certificate_signing_request_approval(self, name, **kwargs): # noqa: E5
read approval of the specified CertificateSigningRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_certificate_signing_request_approval(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CertificateSigningRequest (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the CertificateSigningRequest (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1CertificateSigningRequest
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1CertificateSigningRequest
"""
kwargs['_return_http_data_only'] = True
return self.read_certificate_signing_request_approval_with_http_info(name, **kwargs) # noqa: E501
@@ -1371,24 +1717,36 @@ def read_certificate_signing_request_approval_with_http_info(self, name, **kwarg
read approval of the specified CertificateSigningRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_certificate_signing_request_approval_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CertificateSigningRequest (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the CertificateSigningRequest (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1CertificateSigningRequest, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1CertificateSigningRequest, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1402,7 +1760,10 @@ def read_certificate_signing_request_approval_with_http_info(self, name, **kwarg
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1415,8 +1776,7 @@ def read_certificate_signing_request_approval_with_http_info(self, name, **kwarg
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_certificate_signing_request_approval`") # noqa: E501
collection_formats = {}
@@ -1426,10 +1786,10 @@ def read_certificate_signing_request_approval_with_http_info(self, name, **kwarg
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1442,6 +1802,11 @@ def read_certificate_signing_request_approval_with_http_info(self, name, **kwarg
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1CertificateSigningRequest",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1/certificatesigningrequests/{name}/approval', 'GET',
path_params,
@@ -1450,13 +1815,14 @@ def read_certificate_signing_request_approval_with_http_info(self, name, **kwarg
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1CertificateSigningRequest', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_certificate_signing_request_status(self, name, **kwargs): # noqa: E501
"""read_certificate_signing_request_status # noqa: E501
@@ -1464,22 +1830,28 @@ def read_certificate_signing_request_status(self, name, **kwargs): # noqa: E501
read status of the specified CertificateSigningRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_certificate_signing_request_status(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CertificateSigningRequest (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the CertificateSigningRequest (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1CertificateSigningRequest
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1CertificateSigningRequest
"""
kwargs['_return_http_data_only'] = True
return self.read_certificate_signing_request_status_with_http_info(name, **kwargs) # noqa: E501
@@ -1490,24 +1862,36 @@ def read_certificate_signing_request_status_with_http_info(self, name, **kwargs)
read status of the specified CertificateSigningRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_certificate_signing_request_status_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CertificateSigningRequest (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the CertificateSigningRequest (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1CertificateSigningRequest, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1CertificateSigningRequest, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1521,7 +1905,10 @@ def read_certificate_signing_request_status_with_http_info(self, name, **kwargs)
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1534,8 +1921,7 @@ def read_certificate_signing_request_status_with_http_info(self, name, **kwargs)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_certificate_signing_request_status`") # noqa: E501
collection_formats = {}
@@ -1545,10 +1931,10 @@ def read_certificate_signing_request_status_with_http_info(self, name, **kwargs)
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1561,6 +1947,11 @@ def read_certificate_signing_request_status_with_http_info(self, name, **kwargs)
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1CertificateSigningRequest",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1/certificatesigningrequests/{name}/status', 'GET',
path_params,
@@ -1569,13 +1960,14 @@ def read_certificate_signing_request_status_with_http_info(self, name, **kwargs)
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1CertificateSigningRequest', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_certificate_signing_request(self, name, body, **kwargs): # noqa: E501
"""replace_certificate_signing_request # noqa: E501
@@ -1583,26 +1975,36 @@ def replace_certificate_signing_request(self, name, body, **kwargs): # noqa: E5
replace the specified CertificateSigningRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_certificate_signing_request(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CertificateSigningRequest (required)
- :param V1CertificateSigningRequest body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the CertificateSigningRequest (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1CertificateSigningRequest
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1CertificateSigningRequest
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1CertificateSigningRequest
"""
kwargs['_return_http_data_only'] = True
return self.replace_certificate_signing_request_with_http_info(name, body, **kwargs) # noqa: E501
@@ -1613,28 +2015,44 @@ def replace_certificate_signing_request_with_http_info(self, name, body, **kwarg
replace the specified CertificateSigningRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_certificate_signing_request_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CertificateSigningRequest (required)
- :param V1CertificateSigningRequest body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the CertificateSigningRequest (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1CertificateSigningRequest
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1CertificateSigningRequest, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1CertificateSigningRequest, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1652,7 +2070,10 @@ def replace_certificate_signing_request_with_http_info(self, name, body, **kwarg
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1665,12 +2086,10 @@ def replace_certificate_signing_request_with_http_info(self, name, body, **kwarg
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_certificate_signing_request`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_certificate_signing_request`") # noqa: E501
collection_formats = {}
@@ -1680,16 +2099,16 @@ def replace_certificate_signing_request_with_http_info(self, name, body, **kwarg
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1704,6 +2123,12 @@ def replace_certificate_signing_request_with_http_info(self, name, body, **kwarg
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1CertificateSigningRequest",
+ 201: "V1CertificateSigningRequest",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1/certificatesigningrequests/{name}', 'PUT',
path_params,
@@ -1712,13 +2137,14 @@ def replace_certificate_signing_request_with_http_info(self, name, body, **kwarg
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1CertificateSigningRequest', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_certificate_signing_request_approval(self, name, body, **kwargs): # noqa: E501
"""replace_certificate_signing_request_approval # noqa: E501
@@ -1726,26 +2152,36 @@ def replace_certificate_signing_request_approval(self, name, body, **kwargs): #
replace approval of the specified CertificateSigningRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_certificate_signing_request_approval(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CertificateSigningRequest (required)
- :param V1CertificateSigningRequest body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the CertificateSigningRequest (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1CertificateSigningRequest
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1CertificateSigningRequest
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1CertificateSigningRequest
"""
kwargs['_return_http_data_only'] = True
return self.replace_certificate_signing_request_approval_with_http_info(name, body, **kwargs) # noqa: E501
@@ -1756,28 +2192,44 @@ def replace_certificate_signing_request_approval_with_http_info(self, name, body
replace approval of the specified CertificateSigningRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_certificate_signing_request_approval_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CertificateSigningRequest (required)
- :param V1CertificateSigningRequest body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the CertificateSigningRequest (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1CertificateSigningRequest
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1CertificateSigningRequest, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1CertificateSigningRequest, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1795,7 +2247,10 @@ def replace_certificate_signing_request_approval_with_http_info(self, name, body
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1808,12 +2263,10 @@ def replace_certificate_signing_request_approval_with_http_info(self, name, body
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_certificate_signing_request_approval`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_certificate_signing_request_approval`") # noqa: E501
collection_formats = {}
@@ -1823,16 +2276,16 @@ def replace_certificate_signing_request_approval_with_http_info(self, name, body
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1847,6 +2300,12 @@ def replace_certificate_signing_request_approval_with_http_info(self, name, body
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1CertificateSigningRequest",
+ 201: "V1CertificateSigningRequest",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1/certificatesigningrequests/{name}/approval', 'PUT',
path_params,
@@ -1855,13 +2314,14 @@ def replace_certificate_signing_request_approval_with_http_info(self, name, body
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1CertificateSigningRequest', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_certificate_signing_request_status(self, name, body, **kwargs): # noqa: E501
"""replace_certificate_signing_request_status # noqa: E501
@@ -1869,26 +2329,36 @@ def replace_certificate_signing_request_status(self, name, body, **kwargs): # n
replace status of the specified CertificateSigningRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_certificate_signing_request_status(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CertificateSigningRequest (required)
- :param V1CertificateSigningRequest body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the CertificateSigningRequest (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1CertificateSigningRequest
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1CertificateSigningRequest
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1CertificateSigningRequest
"""
kwargs['_return_http_data_only'] = True
return self.replace_certificate_signing_request_status_with_http_info(name, body, **kwargs) # noqa: E501
@@ -1899,28 +2369,44 @@ def replace_certificate_signing_request_status_with_http_info(self, name, body,
replace status of the specified CertificateSigningRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_certificate_signing_request_status_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the CertificateSigningRequest (required)
- :param V1CertificateSigningRequest body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the CertificateSigningRequest (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1CertificateSigningRequest
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1CertificateSigningRequest, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1CertificateSigningRequest, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1938,7 +2424,10 @@ def replace_certificate_signing_request_status_with_http_info(self, name, body,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1951,12 +2440,10 @@ def replace_certificate_signing_request_status_with_http_info(self, name, body,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_certificate_signing_request_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_certificate_signing_request_status`") # noqa: E501
collection_formats = {}
@@ -1966,16 +2453,16 @@ def replace_certificate_signing_request_status_with_http_info(self, name, body,
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1990,6 +2477,12 @@ def replace_certificate_signing_request_status_with_http_info(self, name, body,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1CertificateSigningRequest",
+ 201: "V1CertificateSigningRequest",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1/certificatesigningrequests/{name}/status', 'PUT',
path_params,
@@ -1998,10 +2491,11 @@ def replace_certificate_signing_request_status_with_http_info(self, name, body,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1CertificateSigningRequest', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/certificates_v1alpha1_api.py b/kubernetes/client/api/certificates_v1alpha1_api.py
index c60ce89584..fa9e944300 100644
--- a/kubernetes/client/api/certificates_v1alpha1_api.py
+++ b/kubernetes/client/api/certificates_v1alpha1_api.py
@@ -42,25 +42,34 @@ def create_cluster_trust_bundle(self, body, **kwargs): # noqa: E501
create a ClusterTrustBundle # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_cluster_trust_bundle(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1alpha1ClusterTrustBundle body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1alpha1ClusterTrustBundle
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1alpha1ClusterTrustBundle
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1alpha1ClusterTrustBundle
"""
kwargs['_return_http_data_only'] = True
return self.create_cluster_trust_bundle_with_http_info(body, **kwargs) # noqa: E501
@@ -71,27 +80,42 @@ def create_cluster_trust_bundle_with_http_info(self, body, **kwargs): # noqa: E
create a ClusterTrustBundle # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_cluster_trust_bundle_with_http_info(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1alpha1ClusterTrustBundle body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1alpha1ClusterTrustBundle
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1alpha1ClusterTrustBundle, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1alpha1ClusterTrustBundle, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -108,7 +132,10 @@ def create_cluster_trust_bundle_with_http_info(self, body, **kwargs): # noqa: E
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -121,8 +148,7 @@ def create_cluster_trust_bundle_with_http_info(self, body, **kwargs): # noqa: E
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_cluster_trust_bundle`") # noqa: E501
collection_formats = {}
@@ -130,16 +156,16 @@ def create_cluster_trust_bundle_with_http_info(self, body, **kwargs): # noqa: E
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -154,6 +180,13 @@ def create_cluster_trust_bundle_with_http_info(self, body, **kwargs): # noqa: E
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1alpha1ClusterTrustBundle",
+ 201: "V1alpha1ClusterTrustBundle",
+ 202: "V1alpha1ClusterTrustBundle",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1alpha1/clustertrustbundles', 'POST',
path_params,
@@ -162,13 +195,14 @@ def create_cluster_trust_bundle_with_http_info(self, body, **kwargs): # noqa: E
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1alpha1ClusterTrustBundle', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_cluster_trust_bundle(self, name, **kwargs): # noqa: E501
"""delete_cluster_trust_bundle # noqa: E501
@@ -176,28 +210,40 @@ def delete_cluster_trust_bundle(self, name, **kwargs): # noqa: E501
delete a ClusterTrustBundle # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_cluster_trust_bundle(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ClusterTrustBundle (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the ClusterTrustBundle (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_cluster_trust_bundle_with_http_info(name, **kwargs) # noqa: E501
@@ -208,30 +254,48 @@ def delete_cluster_trust_bundle_with_http_info(self, name, **kwargs): # noqa: E
delete a ClusterTrustBundle # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_cluster_trust_bundle_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ClusterTrustBundle (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the ClusterTrustBundle (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -251,7 +315,10 @@ def delete_cluster_trust_bundle_with_http_info(self, name, **kwargs): # noqa: E
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -264,8 +331,7 @@ def delete_cluster_trust_bundle_with_http_info(self, name, **kwargs): # noqa: E
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_cluster_trust_bundle`") # noqa: E501
collection_formats = {}
@@ -275,20 +341,20 @@ def delete_cluster_trust_bundle_with_http_info(self, name, **kwargs): # noqa: E
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -303,6 +369,12 @@ def delete_cluster_trust_bundle_with_http_info(self, name, **kwargs): # noqa: E
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1alpha1/clustertrustbundles/{name}', 'DELETE',
path_params,
@@ -311,13 +383,14 @@ def delete_cluster_trust_bundle_with_http_info(self, name, **kwargs): # noqa: E
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_cluster_trust_bundle(self, **kwargs): # noqa: E501
"""delete_collection_cluster_trust_bundle # noqa: E501
@@ -325,35 +398,54 @@ def delete_collection_cluster_trust_bundle(self, **kwargs): # noqa: E501
delete collection of ClusterTrustBundle # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_cluster_trust_bundle(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_cluster_trust_bundle_with_http_info(**kwargs) # noqa: E501
@@ -364,37 +456,62 @@ def delete_collection_cluster_trust_bundle_with_http_info(self, **kwargs): # no
delete collection of ClusterTrustBundle # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_cluster_trust_bundle_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -421,7 +538,10 @@ def delete_collection_cluster_trust_bundle_with_http_info(self, **kwargs): # no
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -439,36 +559,36 @@ def delete_collection_cluster_trust_bundle_with_http_info(self, **kwargs): # no
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -483,6 +603,11 @@ def delete_collection_cluster_trust_bundle_with_http_info(self, **kwargs): # no
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1alpha1/clustertrustbundles', 'DELETE',
path_params,
@@ -491,13 +616,14 @@ def delete_collection_cluster_trust_bundle_with_http_info(self, **kwargs): # no
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def get_api_resources(self, **kwargs): # noqa: E501
"""get_api_resources # noqa: E501
@@ -505,20 +631,24 @@ def get_api_resources(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIResourceList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIResourceList
"""
kwargs['_return_http_data_only'] = True
return self.get_api_resources_with_http_info(**kwargs) # noqa: E501
@@ -529,22 +659,32 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -556,7 +696,10 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -575,7 +718,7 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -588,6 +731,11 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIResourceList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1alpha1/', 'GET',
path_params,
@@ -596,13 +744,14 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIResourceList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_cluster_trust_bundle(self, **kwargs): # noqa: E501
"""list_cluster_trust_bundle # noqa: E501
@@ -610,31 +759,46 @@ def list_cluster_trust_bundle(self, **kwargs): # noqa: E501
list or watch objects of kind ClusterTrustBundle # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_cluster_trust_bundle(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1alpha1ClusterTrustBundleList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1alpha1ClusterTrustBundleList
"""
kwargs['_return_http_data_only'] = True
return self.list_cluster_trust_bundle_with_http_info(**kwargs) # noqa: E501
@@ -645,33 +809,54 @@ def list_cluster_trust_bundle_with_http_info(self, **kwargs): # noqa: E501
list or watch objects of kind ClusterTrustBundle # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_cluster_trust_bundle_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1alpha1ClusterTrustBundleList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1alpha1ClusterTrustBundleList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -694,7 +879,10 @@ def list_cluster_trust_bundle_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -712,30 +900,30 @@ def list_cluster_trust_bundle_with_http_info(self, **kwargs): # noqa: E501
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -748,6 +936,11 @@ def list_cluster_trust_bundle_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1alpha1ClusterTrustBundleList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1alpha1/clustertrustbundles', 'GET',
path_params,
@@ -756,13 +949,14 @@ def list_cluster_trust_bundle_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1alpha1ClusterTrustBundleList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_cluster_trust_bundle(self, name, body, **kwargs): # noqa: E501
"""patch_cluster_trust_bundle # noqa: E501
@@ -770,27 +964,38 @@ def patch_cluster_trust_bundle(self, name, body, **kwargs): # noqa: E501
partially update the specified ClusterTrustBundle # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_cluster_trust_bundle(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ClusterTrustBundle (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ClusterTrustBundle (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1alpha1ClusterTrustBundle
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1alpha1ClusterTrustBundle
"""
kwargs['_return_http_data_only'] = True
return self.patch_cluster_trust_bundle_with_http_info(name, body, **kwargs) # noqa: E501
@@ -801,29 +1006,46 @@ def patch_cluster_trust_bundle_with_http_info(self, name, body, **kwargs): # no
partially update the specified ClusterTrustBundle # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_cluster_trust_bundle_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ClusterTrustBundle (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ClusterTrustBundle (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1alpha1ClusterTrustBundle, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1alpha1ClusterTrustBundle, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -842,7 +1064,10 @@ def patch_cluster_trust_bundle_with_http_info(self, name, body, **kwargs): # no
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -855,12 +1080,10 @@ def patch_cluster_trust_bundle_with_http_info(self, name, body, **kwargs): # no
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_cluster_trust_bundle`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_cluster_trust_bundle`") # noqa: E501
collection_formats = {}
@@ -870,18 +1093,18 @@ def patch_cluster_trust_bundle_with_http_info(self, name, body, **kwargs): # no
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -894,12 +1117,22 @@ def patch_cluster_trust_bundle_with_http_info(self, name, body, **kwargs): # no
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1alpha1ClusterTrustBundle",
+ 201: "V1alpha1ClusterTrustBundle",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1alpha1/clustertrustbundles/{name}', 'PATCH',
path_params,
@@ -908,13 +1141,14 @@ def patch_cluster_trust_bundle_with_http_info(self, name, body, **kwargs): # no
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1alpha1ClusterTrustBundle', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_cluster_trust_bundle(self, name, **kwargs): # noqa: E501
"""read_cluster_trust_bundle # noqa: E501
@@ -922,22 +1156,28 @@ def read_cluster_trust_bundle(self, name, **kwargs): # noqa: E501
read the specified ClusterTrustBundle # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_cluster_trust_bundle(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ClusterTrustBundle (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ClusterTrustBundle (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1alpha1ClusterTrustBundle
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1alpha1ClusterTrustBundle
"""
kwargs['_return_http_data_only'] = True
return self.read_cluster_trust_bundle_with_http_info(name, **kwargs) # noqa: E501
@@ -948,24 +1188,36 @@ def read_cluster_trust_bundle_with_http_info(self, name, **kwargs): # noqa: E50
read the specified ClusterTrustBundle # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_cluster_trust_bundle_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ClusterTrustBundle (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ClusterTrustBundle (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1alpha1ClusterTrustBundle, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1alpha1ClusterTrustBundle, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -979,7 +1231,10 @@ def read_cluster_trust_bundle_with_http_info(self, name, **kwargs): # noqa: E50
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -992,8 +1247,7 @@ def read_cluster_trust_bundle_with_http_info(self, name, **kwargs): # noqa: E50
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_cluster_trust_bundle`") # noqa: E501
collection_formats = {}
@@ -1003,10 +1257,10 @@ def read_cluster_trust_bundle_with_http_info(self, name, **kwargs): # noqa: E50
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1019,6 +1273,11 @@ def read_cluster_trust_bundle_with_http_info(self, name, **kwargs): # noqa: E50
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1alpha1ClusterTrustBundle",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1alpha1/clustertrustbundles/{name}', 'GET',
path_params,
@@ -1027,13 +1286,14 @@ def read_cluster_trust_bundle_with_http_info(self, name, **kwargs): # noqa: E50
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1alpha1ClusterTrustBundle', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_cluster_trust_bundle(self, name, body, **kwargs): # noqa: E501
"""replace_cluster_trust_bundle # noqa: E501
@@ -1041,26 +1301,36 @@ def replace_cluster_trust_bundle(self, name, body, **kwargs): # noqa: E501
replace the specified ClusterTrustBundle # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_cluster_trust_bundle(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ClusterTrustBundle (required)
- :param V1alpha1ClusterTrustBundle body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ClusterTrustBundle (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1alpha1ClusterTrustBundle
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1alpha1ClusterTrustBundle
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1alpha1ClusterTrustBundle
"""
kwargs['_return_http_data_only'] = True
return self.replace_cluster_trust_bundle_with_http_info(name, body, **kwargs) # noqa: E501
@@ -1071,28 +1341,44 @@ def replace_cluster_trust_bundle_with_http_info(self, name, body, **kwargs): #
replace the specified ClusterTrustBundle # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_cluster_trust_bundle_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ClusterTrustBundle (required)
- :param V1alpha1ClusterTrustBundle body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ClusterTrustBundle (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1alpha1ClusterTrustBundle
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1alpha1ClusterTrustBundle, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1alpha1ClusterTrustBundle, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1110,7 +1396,10 @@ def replace_cluster_trust_bundle_with_http_info(self, name, body, **kwargs): #
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1123,12 +1412,10 @@ def replace_cluster_trust_bundle_with_http_info(self, name, body, **kwargs): #
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_cluster_trust_bundle`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_cluster_trust_bundle`") # noqa: E501
collection_formats = {}
@@ -1138,16 +1425,16 @@ def replace_cluster_trust_bundle_with_http_info(self, name, body, **kwargs): #
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1162,6 +1449,12 @@ def replace_cluster_trust_bundle_with_http_info(self, name, body, **kwargs): #
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1alpha1ClusterTrustBundle",
+ 201: "V1alpha1ClusterTrustBundle",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1alpha1/clustertrustbundles/{name}', 'PUT',
path_params,
@@ -1170,10 +1463,11 @@ def replace_cluster_trust_bundle_with_http_info(self, name, body, **kwargs): #
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1alpha1ClusterTrustBundle', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/certificates_v1beta1_api.py b/kubernetes/client/api/certificates_v1beta1_api.py
index 7632bb77a8..75dcf4b26d 100644
--- a/kubernetes/client/api/certificates_v1beta1_api.py
+++ b/kubernetes/client/api/certificates_v1beta1_api.py
@@ -42,25 +42,34 @@ def create_cluster_trust_bundle(self, body, **kwargs): # noqa: E501
create a ClusterTrustBundle # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_cluster_trust_bundle(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1beta1ClusterTrustBundle body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1beta1ClusterTrustBundle
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1ClusterTrustBundle
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1ClusterTrustBundle
"""
kwargs['_return_http_data_only'] = True
return self.create_cluster_trust_bundle_with_http_info(body, **kwargs) # noqa: E501
@@ -71,27 +80,42 @@ def create_cluster_trust_bundle_with_http_info(self, body, **kwargs): # noqa: E
create a ClusterTrustBundle # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_cluster_trust_bundle_with_http_info(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1beta1ClusterTrustBundle body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1beta1ClusterTrustBundle
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1ClusterTrustBundle, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1ClusterTrustBundle, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -108,7 +132,10 @@ def create_cluster_trust_bundle_with_http_info(self, body, **kwargs): # noqa: E
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -121,8 +148,7 @@ def create_cluster_trust_bundle_with_http_info(self, body, **kwargs): # noqa: E
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_cluster_trust_bundle`") # noqa: E501
collection_formats = {}
@@ -130,16 +156,16 @@ def create_cluster_trust_bundle_with_http_info(self, body, **kwargs): # noqa: E
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -154,6 +180,13 @@ def create_cluster_trust_bundle_with_http_info(self, body, **kwargs): # noqa: E
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1ClusterTrustBundle",
+ 201: "V1beta1ClusterTrustBundle",
+ 202: "V1beta1ClusterTrustBundle",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1beta1/clustertrustbundles', 'POST',
path_params,
@@ -162,13 +195,14 @@ def create_cluster_trust_bundle_with_http_info(self, body, **kwargs): # noqa: E
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1ClusterTrustBundle', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_namespaced_pod_certificate_request(self, namespace, body, **kwargs): # noqa: E501
"""create_namespaced_pod_certificate_request # noqa: E501
@@ -176,26 +210,36 @@ def create_namespaced_pod_certificate_request(self, namespace, body, **kwargs):
create a PodCertificateRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_pod_certificate_request(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1beta1PodCertificateRequest body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1beta1PodCertificateRequest
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1PodCertificateRequest
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1PodCertificateRequest
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_pod_certificate_request_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -206,28 +250,44 @@ def create_namespaced_pod_certificate_request_with_http_info(self, namespace, bo
create a PodCertificateRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_pod_certificate_request_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1beta1PodCertificateRequest body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1beta1PodCertificateRequest
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1PodCertificateRequest, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1PodCertificateRequest, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -245,7 +305,10 @@ def create_namespaced_pod_certificate_request_with_http_info(self, namespace, bo
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -258,12 +321,10 @@ def create_namespaced_pod_certificate_request_with_http_info(self, namespace, bo
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_pod_certificate_request`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_pod_certificate_request`") # noqa: E501
collection_formats = {}
@@ -273,16 +334,16 @@ def create_namespaced_pod_certificate_request_with_http_info(self, namespace, bo
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -297,6 +358,13 @@ def create_namespaced_pod_certificate_request_with_http_info(self, namespace, bo
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1PodCertificateRequest",
+ 201: "V1beta1PodCertificateRequest",
+ 202: "V1beta1PodCertificateRequest",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1beta1/namespaces/{namespace}/podcertificaterequests', 'POST',
path_params,
@@ -305,13 +373,14 @@ def create_namespaced_pod_certificate_request_with_http_info(self, namespace, bo
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1PodCertificateRequest', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_cluster_trust_bundle(self, name, **kwargs): # noqa: E501
"""delete_cluster_trust_bundle # noqa: E501
@@ -319,28 +388,40 @@ def delete_cluster_trust_bundle(self, name, **kwargs): # noqa: E501
delete a ClusterTrustBundle # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_cluster_trust_bundle(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ClusterTrustBundle (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the ClusterTrustBundle (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_cluster_trust_bundle_with_http_info(name, **kwargs) # noqa: E501
@@ -351,30 +432,48 @@ def delete_cluster_trust_bundle_with_http_info(self, name, **kwargs): # noqa: E
delete a ClusterTrustBundle # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_cluster_trust_bundle_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ClusterTrustBundle (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the ClusterTrustBundle (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -394,7 +493,10 @@ def delete_cluster_trust_bundle_with_http_info(self, name, **kwargs): # noqa: E
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -407,8 +509,7 @@ def delete_cluster_trust_bundle_with_http_info(self, name, **kwargs): # noqa: E
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_cluster_trust_bundle`") # noqa: E501
collection_formats = {}
@@ -418,20 +519,20 @@ def delete_cluster_trust_bundle_with_http_info(self, name, **kwargs): # noqa: E
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -446,6 +547,12 @@ def delete_cluster_trust_bundle_with_http_info(self, name, **kwargs): # noqa: E
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1beta1/clustertrustbundles/{name}', 'DELETE',
path_params,
@@ -454,13 +561,14 @@ def delete_cluster_trust_bundle_with_http_info(self, name, **kwargs): # noqa: E
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_cluster_trust_bundle(self, **kwargs): # noqa: E501
"""delete_collection_cluster_trust_bundle # noqa: E501
@@ -468,35 +576,54 @@ def delete_collection_cluster_trust_bundle(self, **kwargs): # noqa: E501
delete collection of ClusterTrustBundle # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_cluster_trust_bundle(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_cluster_trust_bundle_with_http_info(**kwargs) # noqa: E501
@@ -507,37 +634,62 @@ def delete_collection_cluster_trust_bundle_with_http_info(self, **kwargs): # no
delete collection of ClusterTrustBundle # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_cluster_trust_bundle_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -564,7 +716,10 @@ def delete_collection_cluster_trust_bundle_with_http_info(self, **kwargs): # no
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -582,36 +737,36 @@ def delete_collection_cluster_trust_bundle_with_http_info(self, **kwargs): # no
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -626,6 +781,11 @@ def delete_collection_cluster_trust_bundle_with_http_info(self, **kwargs): # no
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1beta1/clustertrustbundles', 'DELETE',
path_params,
@@ -634,13 +794,14 @@ def delete_collection_cluster_trust_bundle_with_http_info(self, **kwargs): # no
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_namespaced_pod_certificate_request(self, namespace, **kwargs): # noqa: E501
"""delete_collection_namespaced_pod_certificate_request # noqa: E501
@@ -648,36 +809,56 @@ def delete_collection_namespaced_pod_certificate_request(self, namespace, **kwar
delete collection of PodCertificateRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_pod_certificate_request(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_namespaced_pod_certificate_request_with_http_info(namespace, **kwargs) # noqa: E501
@@ -688,38 +869,64 @@ def delete_collection_namespaced_pod_certificate_request_with_http_info(self, na
delete collection of PodCertificateRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_pod_certificate_request_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -747,7 +954,10 @@ def delete_collection_namespaced_pod_certificate_request_with_http_info(self, na
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -760,8 +970,7 @@ def delete_collection_namespaced_pod_certificate_request_with_http_info(self, na
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_pod_certificate_request`") # noqa: E501
collection_formats = {}
@@ -771,36 +980,36 @@ def delete_collection_namespaced_pod_certificate_request_with_http_info(self, na
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -815,6 +1024,11 @@ def delete_collection_namespaced_pod_certificate_request_with_http_info(self, na
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1beta1/namespaces/{namespace}/podcertificaterequests', 'DELETE',
path_params,
@@ -823,13 +1037,14 @@ def delete_collection_namespaced_pod_certificate_request_with_http_info(self, na
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_namespaced_pod_certificate_request(self, name, namespace, **kwargs): # noqa: E501
"""delete_namespaced_pod_certificate_request # noqa: E501
@@ -837,29 +1052,42 @@ def delete_namespaced_pod_certificate_request(self, name, namespace, **kwargs):
delete a PodCertificateRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_pod_certificate_request(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodCertificateRequest (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the PodCertificateRequest (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_namespaced_pod_certificate_request_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -870,31 +1098,50 @@ def delete_namespaced_pod_certificate_request_with_http_info(self, name, namespa
delete a PodCertificateRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_pod_certificate_request_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodCertificateRequest (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the PodCertificateRequest (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -915,7 +1162,10 @@ def delete_namespaced_pod_certificate_request_with_http_info(self, name, namespa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -928,12 +1178,10 @@ def delete_namespaced_pod_certificate_request_with_http_info(self, name, namespa
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_pod_certificate_request`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_pod_certificate_request`") # noqa: E501
collection_formats = {}
@@ -945,20 +1193,20 @@ def delete_namespaced_pod_certificate_request_with_http_info(self, name, namespa
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -973,6 +1221,12 @@ def delete_namespaced_pod_certificate_request_with_http_info(self, name, namespa
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1beta1/namespaces/{namespace}/podcertificaterequests/{name}', 'DELETE',
path_params,
@@ -981,13 +1235,14 @@ def delete_namespaced_pod_certificate_request_with_http_info(self, name, namespa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def get_api_resources(self, **kwargs): # noqa: E501
"""get_api_resources # noqa: E501
@@ -995,20 +1250,24 @@ def get_api_resources(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIResourceList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIResourceList
"""
kwargs['_return_http_data_only'] = True
return self.get_api_resources_with_http_info(**kwargs) # noqa: E501
@@ -1019,22 +1278,32 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1046,7 +1315,10 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1065,7 +1337,7 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1078,6 +1350,11 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIResourceList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1beta1/', 'GET',
path_params,
@@ -1086,13 +1363,14 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIResourceList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_cluster_trust_bundle(self, **kwargs): # noqa: E501
"""list_cluster_trust_bundle # noqa: E501
@@ -1100,31 +1378,46 @@ def list_cluster_trust_bundle(self, **kwargs): # noqa: E501
list or watch objects of kind ClusterTrustBundle # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_cluster_trust_bundle(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1ClusterTrustBundleList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1ClusterTrustBundleList
"""
kwargs['_return_http_data_only'] = True
return self.list_cluster_trust_bundle_with_http_info(**kwargs) # noqa: E501
@@ -1135,33 +1428,54 @@ def list_cluster_trust_bundle_with_http_info(self, **kwargs): # noqa: E501
list or watch objects of kind ClusterTrustBundle # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_cluster_trust_bundle_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1ClusterTrustBundleList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1ClusterTrustBundleList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1184,7 +1498,10 @@ def list_cluster_trust_bundle_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1202,30 +1519,30 @@ def list_cluster_trust_bundle_with_http_info(self, **kwargs): # noqa: E501
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1238,6 +1555,11 @@ def list_cluster_trust_bundle_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1ClusterTrustBundleList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1beta1/clustertrustbundles', 'GET',
path_params,
@@ -1246,13 +1568,14 @@ def list_cluster_trust_bundle_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1ClusterTrustBundleList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_namespaced_pod_certificate_request(self, namespace, **kwargs): # noqa: E501
"""list_namespaced_pod_certificate_request # noqa: E501
@@ -1260,32 +1583,48 @@ def list_namespaced_pod_certificate_request(self, namespace, **kwargs): # noqa:
list or watch objects of kind PodCertificateRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_pod_certificate_request(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1PodCertificateRequestList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1PodCertificateRequestList
"""
kwargs['_return_http_data_only'] = True
return self.list_namespaced_pod_certificate_request_with_http_info(namespace, **kwargs) # noqa: E501
@@ -1296,34 +1635,56 @@ def list_namespaced_pod_certificate_request_with_http_info(self, namespace, **kw
list or watch objects of kind PodCertificateRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_pod_certificate_request_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1PodCertificateRequestList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1PodCertificateRequestList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1347,7 +1708,10 @@ def list_namespaced_pod_certificate_request_with_http_info(self, namespace, **kw
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1360,8 +1724,7 @@ def list_namespaced_pod_certificate_request_with_http_info(self, namespace, **kw
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_pod_certificate_request`") # noqa: E501
collection_formats = {}
@@ -1371,30 +1734,30 @@ def list_namespaced_pod_certificate_request_with_http_info(self, namespace, **kw
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1407,6 +1770,11 @@ def list_namespaced_pod_certificate_request_with_http_info(self, namespace, **kw
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1PodCertificateRequestList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1beta1/namespaces/{namespace}/podcertificaterequests', 'GET',
path_params,
@@ -1415,13 +1783,14 @@ def list_namespaced_pod_certificate_request_with_http_info(self, namespace, **kw
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1PodCertificateRequestList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_pod_certificate_request_for_all_namespaces(self, **kwargs): # noqa: E501
"""list_pod_certificate_request_for_all_namespaces # noqa: E501
@@ -1429,31 +1798,46 @@ def list_pod_certificate_request_for_all_namespaces(self, **kwargs): # noqa: E5
list or watch objects of kind PodCertificateRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_pod_certificate_request_for_all_namespaces(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1PodCertificateRequestList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1PodCertificateRequestList
"""
kwargs['_return_http_data_only'] = True
return self.list_pod_certificate_request_for_all_namespaces_with_http_info(**kwargs) # noqa: E501
@@ -1464,33 +1848,54 @@ def list_pod_certificate_request_for_all_namespaces_with_http_info(self, **kwarg
list or watch objects of kind PodCertificateRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_pod_certificate_request_for_all_namespaces_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1PodCertificateRequestList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1PodCertificateRequestList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1513,7 +1918,10 @@ def list_pod_certificate_request_for_all_namespaces_with_http_info(self, **kwarg
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1531,30 +1939,30 @@ def list_pod_certificate_request_for_all_namespaces_with_http_info(self, **kwarg
path_params = {}
query_params = []
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1567,6 +1975,11 @@ def list_pod_certificate_request_for_all_namespaces_with_http_info(self, **kwarg
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1PodCertificateRequestList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1beta1/podcertificaterequests', 'GET',
path_params,
@@ -1575,13 +1988,14 @@ def list_pod_certificate_request_for_all_namespaces_with_http_info(self, **kwarg
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1PodCertificateRequestList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_cluster_trust_bundle(self, name, body, **kwargs): # noqa: E501
"""patch_cluster_trust_bundle # noqa: E501
@@ -1589,27 +2003,38 @@ def patch_cluster_trust_bundle(self, name, body, **kwargs): # noqa: E501
partially update the specified ClusterTrustBundle # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_cluster_trust_bundle(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ClusterTrustBundle (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ClusterTrustBundle (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1ClusterTrustBundle
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1ClusterTrustBundle
"""
kwargs['_return_http_data_only'] = True
return self.patch_cluster_trust_bundle_with_http_info(name, body, **kwargs) # noqa: E501
@@ -1620,29 +2045,46 @@ def patch_cluster_trust_bundle_with_http_info(self, name, body, **kwargs): # no
partially update the specified ClusterTrustBundle # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_cluster_trust_bundle_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ClusterTrustBundle (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ClusterTrustBundle (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1ClusterTrustBundle, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1ClusterTrustBundle, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1661,7 +2103,10 @@ def patch_cluster_trust_bundle_with_http_info(self, name, body, **kwargs): # no
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1674,12 +2119,10 @@ def patch_cluster_trust_bundle_with_http_info(self, name, body, **kwargs): # no
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_cluster_trust_bundle`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_cluster_trust_bundle`") # noqa: E501
collection_formats = {}
@@ -1689,18 +2132,18 @@ def patch_cluster_trust_bundle_with_http_info(self, name, body, **kwargs): # no
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1713,12 +2156,22 @@ def patch_cluster_trust_bundle_with_http_info(self, name, body, **kwargs): # no
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1ClusterTrustBundle",
+ 201: "V1beta1ClusterTrustBundle",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1beta1/clustertrustbundles/{name}', 'PATCH',
path_params,
@@ -1727,13 +2180,14 @@ def patch_cluster_trust_bundle_with_http_info(self, name, body, **kwargs): # no
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1ClusterTrustBundle', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_pod_certificate_request(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_pod_certificate_request # noqa: E501
@@ -1741,28 +2195,40 @@ def patch_namespaced_pod_certificate_request(self, name, namespace, body, **kwar
partially update the specified PodCertificateRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_pod_certificate_request(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodCertificateRequest (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the PodCertificateRequest (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1PodCertificateRequest
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1PodCertificateRequest
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_pod_certificate_request_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -1773,30 +2239,48 @@ def patch_namespaced_pod_certificate_request_with_http_info(self, name, namespac
partially update the specified PodCertificateRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_pod_certificate_request_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodCertificateRequest (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the PodCertificateRequest (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1PodCertificateRequest, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1PodCertificateRequest, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1816,7 +2300,10 @@ def patch_namespaced_pod_certificate_request_with_http_info(self, name, namespac
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1829,16 +2316,13 @@ def patch_namespaced_pod_certificate_request_with_http_info(self, name, namespac
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_pod_certificate_request`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_pod_certificate_request`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_pod_certificate_request`") # noqa: E501
collection_formats = {}
@@ -1850,18 +2334,18 @@ def patch_namespaced_pod_certificate_request_with_http_info(self, name, namespac
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1874,12 +2358,22 @@ def patch_namespaced_pod_certificate_request_with_http_info(self, name, namespac
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1PodCertificateRequest",
+ 201: "V1beta1PodCertificateRequest",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1beta1/namespaces/{namespace}/podcertificaterequests/{name}', 'PATCH',
path_params,
@@ -1888,13 +2382,14 @@ def patch_namespaced_pod_certificate_request_with_http_info(self, name, namespac
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1PodCertificateRequest', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_pod_certificate_request_status(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_pod_certificate_request_status # noqa: E501
@@ -1902,28 +2397,40 @@ def patch_namespaced_pod_certificate_request_status(self, name, namespace, body,
partially update status of the specified PodCertificateRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_pod_certificate_request_status(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodCertificateRequest (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the PodCertificateRequest (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1PodCertificateRequest
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1PodCertificateRequest
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_pod_certificate_request_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -1934,30 +2441,48 @@ def patch_namespaced_pod_certificate_request_status_with_http_info(self, name, n
partially update status of the specified PodCertificateRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_pod_certificate_request_status_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodCertificateRequest (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the PodCertificateRequest (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1PodCertificateRequest, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1PodCertificateRequest, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1977,7 +2502,10 @@ def patch_namespaced_pod_certificate_request_status_with_http_info(self, name, n
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1990,16 +2518,13 @@ def patch_namespaced_pod_certificate_request_status_with_http_info(self, name, n
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_pod_certificate_request_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_pod_certificate_request_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_pod_certificate_request_status`") # noqa: E501
collection_formats = {}
@@ -2011,18 +2536,18 @@ def patch_namespaced_pod_certificate_request_status_with_http_info(self, name, n
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2035,12 +2560,22 @@ def patch_namespaced_pod_certificate_request_status_with_http_info(self, name, n
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1PodCertificateRequest",
+ 201: "V1beta1PodCertificateRequest",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1beta1/namespaces/{namespace}/podcertificaterequests/{name}/status', 'PATCH',
path_params,
@@ -2049,13 +2584,14 @@ def patch_namespaced_pod_certificate_request_status_with_http_info(self, name, n
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1PodCertificateRequest', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_cluster_trust_bundle(self, name, **kwargs): # noqa: E501
"""read_cluster_trust_bundle # noqa: E501
@@ -2063,22 +2599,28 @@ def read_cluster_trust_bundle(self, name, **kwargs): # noqa: E501
read the specified ClusterTrustBundle # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_cluster_trust_bundle(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ClusterTrustBundle (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ClusterTrustBundle (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1ClusterTrustBundle
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1ClusterTrustBundle
"""
kwargs['_return_http_data_only'] = True
return self.read_cluster_trust_bundle_with_http_info(name, **kwargs) # noqa: E501
@@ -2089,24 +2631,36 @@ def read_cluster_trust_bundle_with_http_info(self, name, **kwargs): # noqa: E50
read the specified ClusterTrustBundle # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_cluster_trust_bundle_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ClusterTrustBundle (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ClusterTrustBundle (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1ClusterTrustBundle, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1ClusterTrustBundle, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2120,7 +2674,10 @@ def read_cluster_trust_bundle_with_http_info(self, name, **kwargs): # noqa: E50
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2133,8 +2690,7 @@ def read_cluster_trust_bundle_with_http_info(self, name, **kwargs): # noqa: E50
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_cluster_trust_bundle`") # noqa: E501
collection_formats = {}
@@ -2144,10 +2700,10 @@ def read_cluster_trust_bundle_with_http_info(self, name, **kwargs): # noqa: E50
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2160,6 +2716,11 @@ def read_cluster_trust_bundle_with_http_info(self, name, **kwargs): # noqa: E50
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1ClusterTrustBundle",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1beta1/clustertrustbundles/{name}', 'GET',
path_params,
@@ -2168,13 +2729,14 @@ def read_cluster_trust_bundle_with_http_info(self, name, **kwargs): # noqa: E50
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1ClusterTrustBundle', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_pod_certificate_request(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_pod_certificate_request # noqa: E501
@@ -2182,23 +2744,30 @@ def read_namespaced_pod_certificate_request(self, name, namespace, **kwargs): #
read the specified PodCertificateRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_pod_certificate_request(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodCertificateRequest (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the PodCertificateRequest (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1PodCertificateRequest
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1PodCertificateRequest
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_pod_certificate_request_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -2209,25 +2778,38 @@ def read_namespaced_pod_certificate_request_with_http_info(self, name, namespace
read the specified PodCertificateRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_pod_certificate_request_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodCertificateRequest (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the PodCertificateRequest (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1PodCertificateRequest, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1PodCertificateRequest, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2242,7 +2824,10 @@ def read_namespaced_pod_certificate_request_with_http_info(self, name, namespace
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2255,12 +2840,10 @@ def read_namespaced_pod_certificate_request_with_http_info(self, name, namespace
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_pod_certificate_request`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_pod_certificate_request`") # noqa: E501
collection_formats = {}
@@ -2272,10 +2855,10 @@ def read_namespaced_pod_certificate_request_with_http_info(self, name, namespace
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2288,6 +2871,11 @@ def read_namespaced_pod_certificate_request_with_http_info(self, name, namespace
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1PodCertificateRequest",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1beta1/namespaces/{namespace}/podcertificaterequests/{name}', 'GET',
path_params,
@@ -2296,13 +2884,14 @@ def read_namespaced_pod_certificate_request_with_http_info(self, name, namespace
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1PodCertificateRequest', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_pod_certificate_request_status(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_pod_certificate_request_status # noqa: E501
@@ -2310,23 +2899,30 @@ def read_namespaced_pod_certificate_request_status(self, name, namespace, **kwar
read status of the specified PodCertificateRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_pod_certificate_request_status(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodCertificateRequest (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the PodCertificateRequest (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1PodCertificateRequest
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1PodCertificateRequest
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_pod_certificate_request_status_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -2337,25 +2933,38 @@ def read_namespaced_pod_certificate_request_status_with_http_info(self, name, na
read status of the specified PodCertificateRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_pod_certificate_request_status_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodCertificateRequest (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the PodCertificateRequest (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1PodCertificateRequest, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1PodCertificateRequest, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2370,7 +2979,10 @@ def read_namespaced_pod_certificate_request_status_with_http_info(self, name, na
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2383,12 +2995,10 @@ def read_namespaced_pod_certificate_request_status_with_http_info(self, name, na
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_pod_certificate_request_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_pod_certificate_request_status`") # noqa: E501
collection_formats = {}
@@ -2400,10 +3010,10 @@ def read_namespaced_pod_certificate_request_status_with_http_info(self, name, na
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2416,6 +3026,11 @@ def read_namespaced_pod_certificate_request_status_with_http_info(self, name, na
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1PodCertificateRequest",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1beta1/namespaces/{namespace}/podcertificaterequests/{name}/status', 'GET',
path_params,
@@ -2424,13 +3039,14 @@ def read_namespaced_pod_certificate_request_status_with_http_info(self, name, na
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1PodCertificateRequest', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_cluster_trust_bundle(self, name, body, **kwargs): # noqa: E501
"""replace_cluster_trust_bundle # noqa: E501
@@ -2438,26 +3054,36 @@ def replace_cluster_trust_bundle(self, name, body, **kwargs): # noqa: E501
replace the specified ClusterTrustBundle # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_cluster_trust_bundle(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ClusterTrustBundle (required)
- :param V1beta1ClusterTrustBundle body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ClusterTrustBundle (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1beta1ClusterTrustBundle
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1ClusterTrustBundle
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1ClusterTrustBundle
"""
kwargs['_return_http_data_only'] = True
return self.replace_cluster_trust_bundle_with_http_info(name, body, **kwargs) # noqa: E501
@@ -2468,28 +3094,44 @@ def replace_cluster_trust_bundle_with_http_info(self, name, body, **kwargs): #
replace the specified ClusterTrustBundle # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_cluster_trust_bundle_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ClusterTrustBundle (required)
- :param V1beta1ClusterTrustBundle body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ClusterTrustBundle (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1beta1ClusterTrustBundle
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1ClusterTrustBundle, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1ClusterTrustBundle, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2507,7 +3149,10 @@ def replace_cluster_trust_bundle_with_http_info(self, name, body, **kwargs): #
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2520,12 +3165,10 @@ def replace_cluster_trust_bundle_with_http_info(self, name, body, **kwargs): #
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_cluster_trust_bundle`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_cluster_trust_bundle`") # noqa: E501
collection_formats = {}
@@ -2535,16 +3178,16 @@ def replace_cluster_trust_bundle_with_http_info(self, name, body, **kwargs): #
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2559,6 +3202,12 @@ def replace_cluster_trust_bundle_with_http_info(self, name, body, **kwargs): #
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1ClusterTrustBundle",
+ 201: "V1beta1ClusterTrustBundle",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1beta1/clustertrustbundles/{name}', 'PUT',
path_params,
@@ -2567,13 +3216,14 @@ def replace_cluster_trust_bundle_with_http_info(self, name, body, **kwargs): #
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1ClusterTrustBundle', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_pod_certificate_request(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_pod_certificate_request # noqa: E501
@@ -2581,27 +3231,38 @@ def replace_namespaced_pod_certificate_request(self, name, namespace, body, **kw
replace the specified PodCertificateRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_pod_certificate_request(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodCertificateRequest (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1beta1PodCertificateRequest body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the PodCertificateRequest (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1beta1PodCertificateRequest
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1PodCertificateRequest
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1PodCertificateRequest
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_pod_certificate_request_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -2612,29 +3273,46 @@ def replace_namespaced_pod_certificate_request_with_http_info(self, name, namesp
replace the specified PodCertificateRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_pod_certificate_request_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodCertificateRequest (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1beta1PodCertificateRequest body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the PodCertificateRequest (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1beta1PodCertificateRequest
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1PodCertificateRequest, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1PodCertificateRequest, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2653,7 +3331,10 @@ def replace_namespaced_pod_certificate_request_with_http_info(self, name, namesp
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2666,16 +3347,13 @@ def replace_namespaced_pod_certificate_request_with_http_info(self, name, namesp
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_pod_certificate_request`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_pod_certificate_request`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_pod_certificate_request`") # noqa: E501
collection_formats = {}
@@ -2687,16 +3365,16 @@ def replace_namespaced_pod_certificate_request_with_http_info(self, name, namesp
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2711,6 +3389,12 @@ def replace_namespaced_pod_certificate_request_with_http_info(self, name, namesp
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1PodCertificateRequest",
+ 201: "V1beta1PodCertificateRequest",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1beta1/namespaces/{namespace}/podcertificaterequests/{name}', 'PUT',
path_params,
@@ -2719,13 +3403,14 @@ def replace_namespaced_pod_certificate_request_with_http_info(self, name, namesp
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1PodCertificateRequest', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_pod_certificate_request_status(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_pod_certificate_request_status # noqa: E501
@@ -2733,27 +3418,38 @@ def replace_namespaced_pod_certificate_request_status(self, name, namespace, bod
replace status of the specified PodCertificateRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_pod_certificate_request_status(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodCertificateRequest (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1beta1PodCertificateRequest body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the PodCertificateRequest (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1beta1PodCertificateRequest
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1PodCertificateRequest
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1PodCertificateRequest
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_pod_certificate_request_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -2764,29 +3460,46 @@ def replace_namespaced_pod_certificate_request_status_with_http_info(self, name,
replace status of the specified PodCertificateRequest # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_pod_certificate_request_status_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodCertificateRequest (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1beta1PodCertificateRequest body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the PodCertificateRequest (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1beta1PodCertificateRequest
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1PodCertificateRequest, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1PodCertificateRequest, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2805,7 +3518,10 @@ def replace_namespaced_pod_certificate_request_status_with_http_info(self, name,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2818,16 +3534,13 @@ def replace_namespaced_pod_certificate_request_status_with_http_info(self, name,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_pod_certificate_request_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_pod_certificate_request_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_pod_certificate_request_status`") # noqa: E501
collection_formats = {}
@@ -2839,16 +3552,16 @@ def replace_namespaced_pod_certificate_request_status_with_http_info(self, name,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2863,6 +3576,12 @@ def replace_namespaced_pod_certificate_request_status_with_http_info(self, name,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1PodCertificateRequest",
+ 201: "V1beta1PodCertificateRequest",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/certificates.k8s.io/v1beta1/namespaces/{namespace}/podcertificaterequests/{name}/status', 'PUT',
path_params,
@@ -2871,10 +3590,11 @@ def replace_namespaced_pod_certificate_request_status_with_http_info(self, name,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1PodCertificateRequest', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/coordination_api.py b/kubernetes/client/api/coordination_api.py
index b7a8179bae..6fe365d750 100644
--- a/kubernetes/client/api/coordination_api.py
+++ b/kubernetes/client/api/coordination_api.py
@@ -42,20 +42,24 @@ def get_api_group(self, **kwargs): # noqa: E501
get information of a group # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_group(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIGroup
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIGroup
"""
kwargs['_return_http_data_only'] = True
return self.get_api_group_with_http_info(**kwargs) # noqa: E501
@@ -66,22 +70,32 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
get information of a group # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_group_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIGroup, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIGroup, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -93,7 +107,10 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -112,7 +129,7 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -125,6 +142,11 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIGroup",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/coordination.k8s.io/', 'GET',
path_params,
@@ -133,10 +155,11 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIGroup', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/coordination_v1_api.py b/kubernetes/client/api/coordination_v1_api.py
index c22ffd87f0..7b7dfaeeeb 100644
--- a/kubernetes/client/api/coordination_v1_api.py
+++ b/kubernetes/client/api/coordination_v1_api.py
@@ -42,26 +42,36 @@ def create_namespaced_lease(self, namespace, body, **kwargs): # noqa: E501
create a Lease # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_lease(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Lease body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Lease
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Lease
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Lease
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_lease_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -72,28 +82,44 @@ def create_namespaced_lease_with_http_info(self, namespace, body, **kwargs): #
create a Lease # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_lease_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Lease body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Lease
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Lease, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Lease, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -111,7 +137,10 @@ def create_namespaced_lease_with_http_info(self, namespace, body, **kwargs): #
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -124,12 +153,10 @@ def create_namespaced_lease_with_http_info(self, namespace, body, **kwargs): #
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_lease`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_lease`") # noqa: E501
collection_formats = {}
@@ -139,16 +166,16 @@ def create_namespaced_lease_with_http_info(self, namespace, body, **kwargs): #
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -163,6 +190,13 @@ def create_namespaced_lease_with_http_info(self, namespace, body, **kwargs): #
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Lease",
+ 201: "V1Lease",
+ 202: "V1Lease",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/coordination.k8s.io/v1/namespaces/{namespace}/leases', 'POST',
path_params,
@@ -171,13 +205,14 @@ def create_namespaced_lease_with_http_info(self, namespace, body, **kwargs): #
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Lease', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_namespaced_lease(self, namespace, **kwargs): # noqa: E501
"""delete_collection_namespaced_lease # noqa: E501
@@ -185,36 +220,56 @@ def delete_collection_namespaced_lease(self, namespace, **kwargs): # noqa: E501
delete collection of Lease # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_lease(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_namespaced_lease_with_http_info(namespace, **kwargs) # noqa: E501
@@ -225,38 +280,64 @@ def delete_collection_namespaced_lease_with_http_info(self, namespace, **kwargs)
delete collection of Lease # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_lease_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -284,7 +365,10 @@ def delete_collection_namespaced_lease_with_http_info(self, namespace, **kwargs)
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -297,8 +381,7 @@ def delete_collection_namespaced_lease_with_http_info(self, namespace, **kwargs)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_lease`") # noqa: E501
collection_formats = {}
@@ -308,36 +391,36 @@ def delete_collection_namespaced_lease_with_http_info(self, namespace, **kwargs)
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -352,6 +435,11 @@ def delete_collection_namespaced_lease_with_http_info(self, namespace, **kwargs)
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/coordination.k8s.io/v1/namespaces/{namespace}/leases', 'DELETE',
path_params,
@@ -360,13 +448,14 @@ def delete_collection_namespaced_lease_with_http_info(self, namespace, **kwargs)
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_namespaced_lease(self, name, namespace, **kwargs): # noqa: E501
"""delete_namespaced_lease # noqa: E501
@@ -374,29 +463,42 @@ def delete_namespaced_lease(self, name, namespace, **kwargs): # noqa: E501
delete a Lease # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_lease(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Lease (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the Lease (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_namespaced_lease_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -407,31 +509,50 @@ def delete_namespaced_lease_with_http_info(self, name, namespace, **kwargs): #
delete a Lease # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_lease_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Lease (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the Lease (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -452,7 +573,10 @@ def delete_namespaced_lease_with_http_info(self, name, namespace, **kwargs): #
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -465,12 +589,10 @@ def delete_namespaced_lease_with_http_info(self, name, namespace, **kwargs): #
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_lease`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_lease`") # noqa: E501
collection_formats = {}
@@ -482,20 +604,20 @@ def delete_namespaced_lease_with_http_info(self, name, namespace, **kwargs): #
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -510,6 +632,12 @@ def delete_namespaced_lease_with_http_info(self, name, namespace, **kwargs): #
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/coordination.k8s.io/v1/namespaces/{namespace}/leases/{name}', 'DELETE',
path_params,
@@ -518,13 +646,14 @@ def delete_namespaced_lease_with_http_info(self, name, namespace, **kwargs): #
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def get_api_resources(self, **kwargs): # noqa: E501
"""get_api_resources # noqa: E501
@@ -532,20 +661,24 @@ def get_api_resources(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIResourceList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIResourceList
"""
kwargs['_return_http_data_only'] = True
return self.get_api_resources_with_http_info(**kwargs) # noqa: E501
@@ -556,22 +689,32 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -583,7 +726,10 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -602,7 +748,7 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -615,6 +761,11 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIResourceList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/coordination.k8s.io/v1/', 'GET',
path_params,
@@ -623,13 +774,14 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIResourceList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_lease_for_all_namespaces(self, **kwargs): # noqa: E501
"""list_lease_for_all_namespaces # noqa: E501
@@ -637,31 +789,46 @@ def list_lease_for_all_namespaces(self, **kwargs): # noqa: E501
list or watch objects of kind Lease # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_lease_for_all_namespaces(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1LeaseList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1LeaseList
"""
kwargs['_return_http_data_only'] = True
return self.list_lease_for_all_namespaces_with_http_info(**kwargs) # noqa: E501
@@ -672,33 +839,54 @@ def list_lease_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501
list or watch objects of kind Lease # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_lease_for_all_namespaces_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1LeaseList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1LeaseList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -721,7 +909,10 @@ def list_lease_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -739,30 +930,30 @@ def list_lease_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501
path_params = {}
query_params = []
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -775,6 +966,11 @@ def list_lease_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1LeaseList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/coordination.k8s.io/v1/leases', 'GET',
path_params,
@@ -783,13 +979,14 @@ def list_lease_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1LeaseList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_namespaced_lease(self, namespace, **kwargs): # noqa: E501
"""list_namespaced_lease # noqa: E501
@@ -797,32 +994,48 @@ def list_namespaced_lease(self, namespace, **kwargs): # noqa: E501
list or watch objects of kind Lease # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_lease(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1LeaseList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1LeaseList
"""
kwargs['_return_http_data_only'] = True
return self.list_namespaced_lease_with_http_info(namespace, **kwargs) # noqa: E501
@@ -833,34 +1046,56 @@ def list_namespaced_lease_with_http_info(self, namespace, **kwargs): # noqa: E5
list or watch objects of kind Lease # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_lease_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1LeaseList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1LeaseList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -884,7 +1119,10 @@ def list_namespaced_lease_with_http_info(self, namespace, **kwargs): # noqa: E5
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -897,8 +1135,7 @@ def list_namespaced_lease_with_http_info(self, namespace, **kwargs): # noqa: E5
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_lease`") # noqa: E501
collection_formats = {}
@@ -908,30 +1145,30 @@ def list_namespaced_lease_with_http_info(self, namespace, **kwargs): # noqa: E5
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -944,6 +1181,11 @@ def list_namespaced_lease_with_http_info(self, namespace, **kwargs): # noqa: E5
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1LeaseList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/coordination.k8s.io/v1/namespaces/{namespace}/leases', 'GET',
path_params,
@@ -952,13 +1194,14 @@ def list_namespaced_lease_with_http_info(self, namespace, **kwargs): # noqa: E5
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1LeaseList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_lease(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_lease # noqa: E501
@@ -966,28 +1209,40 @@ def patch_namespaced_lease(self, name, namespace, body, **kwargs): # noqa: E501
partially update the specified Lease # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_lease(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Lease (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Lease (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Lease
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Lease
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_lease_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -998,30 +1253,48 @@ def patch_namespaced_lease_with_http_info(self, name, namespace, body, **kwargs)
partially update the specified Lease # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_lease_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Lease (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Lease (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Lease, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Lease, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1041,7 +1314,10 @@ def patch_namespaced_lease_with_http_info(self, name, namespace, body, **kwargs)
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1054,16 +1330,13 @@ def patch_namespaced_lease_with_http_info(self, name, namespace, body, **kwargs)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_lease`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_lease`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_lease`") # noqa: E501
collection_formats = {}
@@ -1075,18 +1348,18 @@ def patch_namespaced_lease_with_http_info(self, name, namespace, body, **kwargs)
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1099,12 +1372,22 @@ def patch_namespaced_lease_with_http_info(self, name, namespace, body, **kwargs)
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Lease",
+ 201: "V1Lease",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/coordination.k8s.io/v1/namespaces/{namespace}/leases/{name}', 'PATCH',
path_params,
@@ -1113,13 +1396,14 @@ def patch_namespaced_lease_with_http_info(self, name, namespace, body, **kwargs)
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Lease', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_lease(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_lease # noqa: E501
@@ -1127,23 +1411,30 @@ def read_namespaced_lease(self, name, namespace, **kwargs): # noqa: E501
read the specified Lease # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_lease(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Lease (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Lease (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Lease
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Lease
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_lease_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -1154,25 +1445,38 @@ def read_namespaced_lease_with_http_info(self, name, namespace, **kwargs): # no
read the specified Lease # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_lease_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Lease (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Lease (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Lease, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Lease, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1187,7 +1491,10 @@ def read_namespaced_lease_with_http_info(self, name, namespace, **kwargs): # no
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1200,12 +1507,10 @@ def read_namespaced_lease_with_http_info(self, name, namespace, **kwargs): # no
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_lease`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_lease`") # noqa: E501
collection_formats = {}
@@ -1217,10 +1522,10 @@ def read_namespaced_lease_with_http_info(self, name, namespace, **kwargs): # no
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1233,6 +1538,11 @@ def read_namespaced_lease_with_http_info(self, name, namespace, **kwargs): # no
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Lease",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/coordination.k8s.io/v1/namespaces/{namespace}/leases/{name}', 'GET',
path_params,
@@ -1241,13 +1551,14 @@ def read_namespaced_lease_with_http_info(self, name, namespace, **kwargs): # no
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Lease', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_lease(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_lease # noqa: E501
@@ -1255,27 +1566,38 @@ def replace_namespaced_lease(self, name, namespace, body, **kwargs): # noqa: E5
replace the specified Lease # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_lease(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Lease (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Lease body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Lease (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Lease
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Lease
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Lease
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_lease_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -1286,29 +1608,46 @@ def replace_namespaced_lease_with_http_info(self, name, namespace, body, **kwarg
replace the specified Lease # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_lease_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Lease (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Lease body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Lease (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Lease
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Lease, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Lease, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1327,7 +1666,10 @@ def replace_namespaced_lease_with_http_info(self, name, namespace, body, **kwarg
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1340,16 +1682,13 @@ def replace_namespaced_lease_with_http_info(self, name, namespace, body, **kwarg
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_lease`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_lease`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_lease`") # noqa: E501
collection_formats = {}
@@ -1361,16 +1700,16 @@ def replace_namespaced_lease_with_http_info(self, name, namespace, body, **kwarg
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1385,6 +1724,12 @@ def replace_namespaced_lease_with_http_info(self, name, namespace, body, **kwarg
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Lease",
+ 201: "V1Lease",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/coordination.k8s.io/v1/namespaces/{namespace}/leases/{name}', 'PUT',
path_params,
@@ -1393,10 +1738,11 @@ def replace_namespaced_lease_with_http_info(self, name, namespace, body, **kwarg
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Lease', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/coordination_v1alpha2_api.py b/kubernetes/client/api/coordination_v1alpha2_api.py
index a8064e2800..f6633caf00 100644
--- a/kubernetes/client/api/coordination_v1alpha2_api.py
+++ b/kubernetes/client/api/coordination_v1alpha2_api.py
@@ -42,26 +42,36 @@ def create_namespaced_lease_candidate(self, namespace, body, **kwargs): # noqa:
create a LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_lease_candidate(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1alpha2LeaseCandidate body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1alpha2LeaseCandidate
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1alpha2LeaseCandidate
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1alpha2LeaseCandidate
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_lease_candidate_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -72,28 +82,44 @@ def create_namespaced_lease_candidate_with_http_info(self, namespace, body, **kw
create a LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_lease_candidate_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1alpha2LeaseCandidate body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1alpha2LeaseCandidate
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1alpha2LeaseCandidate, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1alpha2LeaseCandidate, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -111,7 +137,10 @@ def create_namespaced_lease_candidate_with_http_info(self, namespace, body, **kw
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -124,12 +153,10 @@ def create_namespaced_lease_candidate_with_http_info(self, namespace, body, **kw
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_lease_candidate`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_lease_candidate`") # noqa: E501
collection_formats = {}
@@ -139,16 +166,16 @@ def create_namespaced_lease_candidate_with_http_info(self, namespace, body, **kw
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -163,6 +190,13 @@ def create_namespaced_lease_candidate_with_http_info(self, namespace, body, **kw
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1alpha2LeaseCandidate",
+ 201: "V1alpha2LeaseCandidate",
+ 202: "V1alpha2LeaseCandidate",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/coordination.k8s.io/v1alpha2/namespaces/{namespace}/leasecandidates', 'POST',
path_params,
@@ -171,13 +205,14 @@ def create_namespaced_lease_candidate_with_http_info(self, namespace, body, **kw
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1alpha2LeaseCandidate', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_namespaced_lease_candidate(self, namespace, **kwargs): # noqa: E501
"""delete_collection_namespaced_lease_candidate # noqa: E501
@@ -185,36 +220,56 @@ def delete_collection_namespaced_lease_candidate(self, namespace, **kwargs): #
delete collection of LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_lease_candidate(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_namespaced_lease_candidate_with_http_info(namespace, **kwargs) # noqa: E501
@@ -225,38 +280,64 @@ def delete_collection_namespaced_lease_candidate_with_http_info(self, namespace,
delete collection of LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_lease_candidate_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -284,7 +365,10 @@ def delete_collection_namespaced_lease_candidate_with_http_info(self, namespace,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -297,8 +381,7 @@ def delete_collection_namespaced_lease_candidate_with_http_info(self, namespace,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_lease_candidate`") # noqa: E501
collection_formats = {}
@@ -308,36 +391,36 @@ def delete_collection_namespaced_lease_candidate_with_http_info(self, namespace,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -352,6 +435,11 @@ def delete_collection_namespaced_lease_candidate_with_http_info(self, namespace,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/coordination.k8s.io/v1alpha2/namespaces/{namespace}/leasecandidates', 'DELETE',
path_params,
@@ -360,13 +448,14 @@ def delete_collection_namespaced_lease_candidate_with_http_info(self, namespace,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_namespaced_lease_candidate(self, name, namespace, **kwargs): # noqa: E501
"""delete_namespaced_lease_candidate # noqa: E501
@@ -374,29 +463,42 @@ def delete_namespaced_lease_candidate(self, name, namespace, **kwargs): # noqa:
delete a LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_lease_candidate(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the LeaseCandidate (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the LeaseCandidate (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_namespaced_lease_candidate_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -407,31 +509,50 @@ def delete_namespaced_lease_candidate_with_http_info(self, name, namespace, **kw
delete a LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_lease_candidate_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the LeaseCandidate (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the LeaseCandidate (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -452,7 +573,10 @@ def delete_namespaced_lease_candidate_with_http_info(self, name, namespace, **kw
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -465,12 +589,10 @@ def delete_namespaced_lease_candidate_with_http_info(self, name, namespace, **kw
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_lease_candidate`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_lease_candidate`") # noqa: E501
collection_formats = {}
@@ -482,20 +604,20 @@ def delete_namespaced_lease_candidate_with_http_info(self, name, namespace, **kw
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -510,6 +632,12 @@ def delete_namespaced_lease_candidate_with_http_info(self, name, namespace, **kw
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/coordination.k8s.io/v1alpha2/namespaces/{namespace}/leasecandidates/{name}', 'DELETE',
path_params,
@@ -518,13 +646,14 @@ def delete_namespaced_lease_candidate_with_http_info(self, name, namespace, **kw
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def get_api_resources(self, **kwargs): # noqa: E501
"""get_api_resources # noqa: E501
@@ -532,20 +661,24 @@ def get_api_resources(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIResourceList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIResourceList
"""
kwargs['_return_http_data_only'] = True
return self.get_api_resources_with_http_info(**kwargs) # noqa: E501
@@ -556,22 +689,32 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -583,7 +726,10 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -602,7 +748,7 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -615,6 +761,11 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIResourceList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/coordination.k8s.io/v1alpha2/', 'GET',
path_params,
@@ -623,13 +774,14 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIResourceList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_lease_candidate_for_all_namespaces(self, **kwargs): # noqa: E501
"""list_lease_candidate_for_all_namespaces # noqa: E501
@@ -637,31 +789,46 @@ def list_lease_candidate_for_all_namespaces(self, **kwargs): # noqa: E501
list or watch objects of kind LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_lease_candidate_for_all_namespaces(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1alpha2LeaseCandidateList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1alpha2LeaseCandidateList
"""
kwargs['_return_http_data_only'] = True
return self.list_lease_candidate_for_all_namespaces_with_http_info(**kwargs) # noqa: E501
@@ -672,33 +839,54 @@ def list_lease_candidate_for_all_namespaces_with_http_info(self, **kwargs): # n
list or watch objects of kind LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_lease_candidate_for_all_namespaces_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1alpha2LeaseCandidateList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1alpha2LeaseCandidateList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -721,7 +909,10 @@ def list_lease_candidate_for_all_namespaces_with_http_info(self, **kwargs): # n
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -739,30 +930,30 @@ def list_lease_candidate_for_all_namespaces_with_http_info(self, **kwargs): # n
path_params = {}
query_params = []
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -775,6 +966,11 @@ def list_lease_candidate_for_all_namespaces_with_http_info(self, **kwargs): # n
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1alpha2LeaseCandidateList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/coordination.k8s.io/v1alpha2/leasecandidates', 'GET',
path_params,
@@ -783,13 +979,14 @@ def list_lease_candidate_for_all_namespaces_with_http_info(self, **kwargs): # n
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1alpha2LeaseCandidateList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_namespaced_lease_candidate(self, namespace, **kwargs): # noqa: E501
"""list_namespaced_lease_candidate # noqa: E501
@@ -797,32 +994,48 @@ def list_namespaced_lease_candidate(self, namespace, **kwargs): # noqa: E501
list or watch objects of kind LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_lease_candidate(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1alpha2LeaseCandidateList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1alpha2LeaseCandidateList
"""
kwargs['_return_http_data_only'] = True
return self.list_namespaced_lease_candidate_with_http_info(namespace, **kwargs) # noqa: E501
@@ -833,34 +1046,56 @@ def list_namespaced_lease_candidate_with_http_info(self, namespace, **kwargs):
list or watch objects of kind LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_lease_candidate_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1alpha2LeaseCandidateList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1alpha2LeaseCandidateList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -884,7 +1119,10 @@ def list_namespaced_lease_candidate_with_http_info(self, namespace, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -897,8 +1135,7 @@ def list_namespaced_lease_candidate_with_http_info(self, namespace, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_lease_candidate`") # noqa: E501
collection_formats = {}
@@ -908,30 +1145,30 @@ def list_namespaced_lease_candidate_with_http_info(self, namespace, **kwargs):
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -944,6 +1181,11 @@ def list_namespaced_lease_candidate_with_http_info(self, namespace, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1alpha2LeaseCandidateList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/coordination.k8s.io/v1alpha2/namespaces/{namespace}/leasecandidates', 'GET',
path_params,
@@ -952,13 +1194,14 @@ def list_namespaced_lease_candidate_with_http_info(self, namespace, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1alpha2LeaseCandidateList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_lease_candidate(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_lease_candidate # noqa: E501
@@ -966,28 +1209,40 @@ def patch_namespaced_lease_candidate(self, name, namespace, body, **kwargs): #
partially update the specified LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_lease_candidate(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the LeaseCandidate (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the LeaseCandidate (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1alpha2LeaseCandidate
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1alpha2LeaseCandidate
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_lease_candidate_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -998,30 +1253,48 @@ def patch_namespaced_lease_candidate_with_http_info(self, name, namespace, body,
partially update the specified LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_lease_candidate_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the LeaseCandidate (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the LeaseCandidate (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1alpha2LeaseCandidate, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1alpha2LeaseCandidate, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1041,7 +1314,10 @@ def patch_namespaced_lease_candidate_with_http_info(self, name, namespace, body,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1054,16 +1330,13 @@ def patch_namespaced_lease_candidate_with_http_info(self, name, namespace, body,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_lease_candidate`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_lease_candidate`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_lease_candidate`") # noqa: E501
collection_formats = {}
@@ -1075,18 +1348,18 @@ def patch_namespaced_lease_candidate_with_http_info(self, name, namespace, body,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1099,12 +1372,22 @@ def patch_namespaced_lease_candidate_with_http_info(self, name, namespace, body,
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1alpha2LeaseCandidate",
+ 201: "V1alpha2LeaseCandidate",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/coordination.k8s.io/v1alpha2/namespaces/{namespace}/leasecandidates/{name}', 'PATCH',
path_params,
@@ -1113,13 +1396,14 @@ def patch_namespaced_lease_candidate_with_http_info(self, name, namespace, body,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1alpha2LeaseCandidate', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_lease_candidate(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_lease_candidate # noqa: E501
@@ -1127,23 +1411,30 @@ def read_namespaced_lease_candidate(self, name, namespace, **kwargs): # noqa: E
read the specified LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_lease_candidate(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the LeaseCandidate (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the LeaseCandidate (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1alpha2LeaseCandidate
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1alpha2LeaseCandidate
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_lease_candidate_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -1154,25 +1445,38 @@ def read_namespaced_lease_candidate_with_http_info(self, name, namespace, **kwar
read the specified LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_lease_candidate_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the LeaseCandidate (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the LeaseCandidate (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1alpha2LeaseCandidate, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1alpha2LeaseCandidate, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1187,7 +1491,10 @@ def read_namespaced_lease_candidate_with_http_info(self, name, namespace, **kwar
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1200,12 +1507,10 @@ def read_namespaced_lease_candidate_with_http_info(self, name, namespace, **kwar
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_lease_candidate`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_lease_candidate`") # noqa: E501
collection_formats = {}
@@ -1217,10 +1522,10 @@ def read_namespaced_lease_candidate_with_http_info(self, name, namespace, **kwar
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1233,6 +1538,11 @@ def read_namespaced_lease_candidate_with_http_info(self, name, namespace, **kwar
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1alpha2LeaseCandidate",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/coordination.k8s.io/v1alpha2/namespaces/{namespace}/leasecandidates/{name}', 'GET',
path_params,
@@ -1241,13 +1551,14 @@ def read_namespaced_lease_candidate_with_http_info(self, name, namespace, **kwar
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1alpha2LeaseCandidate', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_lease_candidate(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_lease_candidate # noqa: E501
@@ -1255,27 +1566,38 @@ def replace_namespaced_lease_candidate(self, name, namespace, body, **kwargs):
replace the specified LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_lease_candidate(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the LeaseCandidate (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1alpha2LeaseCandidate body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the LeaseCandidate (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1alpha2LeaseCandidate
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1alpha2LeaseCandidate
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1alpha2LeaseCandidate
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_lease_candidate_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -1286,29 +1608,46 @@ def replace_namespaced_lease_candidate_with_http_info(self, name, namespace, bod
replace the specified LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_lease_candidate_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the LeaseCandidate (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1alpha2LeaseCandidate body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the LeaseCandidate (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1alpha2LeaseCandidate
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1alpha2LeaseCandidate, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1alpha2LeaseCandidate, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1327,7 +1666,10 @@ def replace_namespaced_lease_candidate_with_http_info(self, name, namespace, bod
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1340,16 +1682,13 @@ def replace_namespaced_lease_candidate_with_http_info(self, name, namespace, bod
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_lease_candidate`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_lease_candidate`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_lease_candidate`") # noqa: E501
collection_formats = {}
@@ -1361,16 +1700,16 @@ def replace_namespaced_lease_candidate_with_http_info(self, name, namespace, bod
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1385,6 +1724,12 @@ def replace_namespaced_lease_candidate_with_http_info(self, name, namespace, bod
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1alpha2LeaseCandidate",
+ 201: "V1alpha2LeaseCandidate",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/coordination.k8s.io/v1alpha2/namespaces/{namespace}/leasecandidates/{name}', 'PUT',
path_params,
@@ -1393,10 +1738,11 @@ def replace_namespaced_lease_candidate_with_http_info(self, name, namespace, bod
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1alpha2LeaseCandidate', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/coordination_v1beta1_api.py b/kubernetes/client/api/coordination_v1beta1_api.py
index b6054b2218..73ac7026e6 100644
--- a/kubernetes/client/api/coordination_v1beta1_api.py
+++ b/kubernetes/client/api/coordination_v1beta1_api.py
@@ -42,26 +42,36 @@ def create_namespaced_lease_candidate(self, namespace, body, **kwargs): # noqa:
create a LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_lease_candidate(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1beta1LeaseCandidate body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1beta1LeaseCandidate
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1LeaseCandidate
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1LeaseCandidate
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_lease_candidate_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -72,28 +82,44 @@ def create_namespaced_lease_candidate_with_http_info(self, namespace, body, **kw
create a LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_lease_candidate_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1beta1LeaseCandidate body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1beta1LeaseCandidate
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1LeaseCandidate, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1LeaseCandidate, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -111,7 +137,10 @@ def create_namespaced_lease_candidate_with_http_info(self, namespace, body, **kw
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -124,12 +153,10 @@ def create_namespaced_lease_candidate_with_http_info(self, namespace, body, **kw
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_lease_candidate`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_lease_candidate`") # noqa: E501
collection_formats = {}
@@ -139,16 +166,16 @@ def create_namespaced_lease_candidate_with_http_info(self, namespace, body, **kw
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -163,6 +190,13 @@ def create_namespaced_lease_candidate_with_http_info(self, namespace, body, **kw
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1LeaseCandidate",
+ 201: "V1beta1LeaseCandidate",
+ 202: "V1beta1LeaseCandidate",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/coordination.k8s.io/v1beta1/namespaces/{namespace}/leasecandidates', 'POST',
path_params,
@@ -171,13 +205,14 @@ def create_namespaced_lease_candidate_with_http_info(self, namespace, body, **kw
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1LeaseCandidate', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_namespaced_lease_candidate(self, namespace, **kwargs): # noqa: E501
"""delete_collection_namespaced_lease_candidate # noqa: E501
@@ -185,36 +220,56 @@ def delete_collection_namespaced_lease_candidate(self, namespace, **kwargs): #
delete collection of LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_lease_candidate(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_namespaced_lease_candidate_with_http_info(namespace, **kwargs) # noqa: E501
@@ -225,38 +280,64 @@ def delete_collection_namespaced_lease_candidate_with_http_info(self, namespace,
delete collection of LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_lease_candidate_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -284,7 +365,10 @@ def delete_collection_namespaced_lease_candidate_with_http_info(self, namespace,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -297,8 +381,7 @@ def delete_collection_namespaced_lease_candidate_with_http_info(self, namespace,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_lease_candidate`") # noqa: E501
collection_formats = {}
@@ -308,36 +391,36 @@ def delete_collection_namespaced_lease_candidate_with_http_info(self, namespace,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -352,6 +435,11 @@ def delete_collection_namespaced_lease_candidate_with_http_info(self, namespace,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/coordination.k8s.io/v1beta1/namespaces/{namespace}/leasecandidates', 'DELETE',
path_params,
@@ -360,13 +448,14 @@ def delete_collection_namespaced_lease_candidate_with_http_info(self, namespace,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_namespaced_lease_candidate(self, name, namespace, **kwargs): # noqa: E501
"""delete_namespaced_lease_candidate # noqa: E501
@@ -374,29 +463,42 @@ def delete_namespaced_lease_candidate(self, name, namespace, **kwargs): # noqa:
delete a LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_lease_candidate(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the LeaseCandidate (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the LeaseCandidate (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_namespaced_lease_candidate_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -407,31 +509,50 @@ def delete_namespaced_lease_candidate_with_http_info(self, name, namespace, **kw
delete a LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_lease_candidate_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the LeaseCandidate (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the LeaseCandidate (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -452,7 +573,10 @@ def delete_namespaced_lease_candidate_with_http_info(self, name, namespace, **kw
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -465,12 +589,10 @@ def delete_namespaced_lease_candidate_with_http_info(self, name, namespace, **kw
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_lease_candidate`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_lease_candidate`") # noqa: E501
collection_formats = {}
@@ -482,20 +604,20 @@ def delete_namespaced_lease_candidate_with_http_info(self, name, namespace, **kw
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -510,6 +632,12 @@ def delete_namespaced_lease_candidate_with_http_info(self, name, namespace, **kw
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/coordination.k8s.io/v1beta1/namespaces/{namespace}/leasecandidates/{name}', 'DELETE',
path_params,
@@ -518,13 +646,14 @@ def delete_namespaced_lease_candidate_with_http_info(self, name, namespace, **kw
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def get_api_resources(self, **kwargs): # noqa: E501
"""get_api_resources # noqa: E501
@@ -532,20 +661,24 @@ def get_api_resources(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIResourceList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIResourceList
"""
kwargs['_return_http_data_only'] = True
return self.get_api_resources_with_http_info(**kwargs) # noqa: E501
@@ -556,22 +689,32 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -583,7 +726,10 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -602,7 +748,7 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -615,6 +761,11 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIResourceList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/coordination.k8s.io/v1beta1/', 'GET',
path_params,
@@ -623,13 +774,14 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIResourceList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_lease_candidate_for_all_namespaces(self, **kwargs): # noqa: E501
"""list_lease_candidate_for_all_namespaces # noqa: E501
@@ -637,31 +789,46 @@ def list_lease_candidate_for_all_namespaces(self, **kwargs): # noqa: E501
list or watch objects of kind LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_lease_candidate_for_all_namespaces(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1LeaseCandidateList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1LeaseCandidateList
"""
kwargs['_return_http_data_only'] = True
return self.list_lease_candidate_for_all_namespaces_with_http_info(**kwargs) # noqa: E501
@@ -672,33 +839,54 @@ def list_lease_candidate_for_all_namespaces_with_http_info(self, **kwargs): # n
list or watch objects of kind LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_lease_candidate_for_all_namespaces_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1LeaseCandidateList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1LeaseCandidateList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -721,7 +909,10 @@ def list_lease_candidate_for_all_namespaces_with_http_info(self, **kwargs): # n
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -739,30 +930,30 @@ def list_lease_candidate_for_all_namespaces_with_http_info(self, **kwargs): # n
path_params = {}
query_params = []
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -775,6 +966,11 @@ def list_lease_candidate_for_all_namespaces_with_http_info(self, **kwargs): # n
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1LeaseCandidateList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/coordination.k8s.io/v1beta1/leasecandidates', 'GET',
path_params,
@@ -783,13 +979,14 @@ def list_lease_candidate_for_all_namespaces_with_http_info(self, **kwargs): # n
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1LeaseCandidateList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_namespaced_lease_candidate(self, namespace, **kwargs): # noqa: E501
"""list_namespaced_lease_candidate # noqa: E501
@@ -797,32 +994,48 @@ def list_namespaced_lease_candidate(self, namespace, **kwargs): # noqa: E501
list or watch objects of kind LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_lease_candidate(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1LeaseCandidateList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1LeaseCandidateList
"""
kwargs['_return_http_data_only'] = True
return self.list_namespaced_lease_candidate_with_http_info(namespace, **kwargs) # noqa: E501
@@ -833,34 +1046,56 @@ def list_namespaced_lease_candidate_with_http_info(self, namespace, **kwargs):
list or watch objects of kind LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_lease_candidate_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1LeaseCandidateList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1LeaseCandidateList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -884,7 +1119,10 @@ def list_namespaced_lease_candidate_with_http_info(self, namespace, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -897,8 +1135,7 @@ def list_namespaced_lease_candidate_with_http_info(self, namespace, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_lease_candidate`") # noqa: E501
collection_formats = {}
@@ -908,30 +1145,30 @@ def list_namespaced_lease_candidate_with_http_info(self, namespace, **kwargs):
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -944,6 +1181,11 @@ def list_namespaced_lease_candidate_with_http_info(self, namespace, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1LeaseCandidateList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/coordination.k8s.io/v1beta1/namespaces/{namespace}/leasecandidates', 'GET',
path_params,
@@ -952,13 +1194,14 @@ def list_namespaced_lease_candidate_with_http_info(self, namespace, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1LeaseCandidateList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_lease_candidate(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_lease_candidate # noqa: E501
@@ -966,28 +1209,40 @@ def patch_namespaced_lease_candidate(self, name, namespace, body, **kwargs): #
partially update the specified LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_lease_candidate(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the LeaseCandidate (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the LeaseCandidate (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1LeaseCandidate
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1LeaseCandidate
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_lease_candidate_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -998,30 +1253,48 @@ def patch_namespaced_lease_candidate_with_http_info(self, name, namespace, body,
partially update the specified LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_lease_candidate_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the LeaseCandidate (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the LeaseCandidate (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1LeaseCandidate, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1LeaseCandidate, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1041,7 +1314,10 @@ def patch_namespaced_lease_candidate_with_http_info(self, name, namespace, body,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1054,16 +1330,13 @@ def patch_namespaced_lease_candidate_with_http_info(self, name, namespace, body,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_lease_candidate`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_lease_candidate`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_lease_candidate`") # noqa: E501
collection_formats = {}
@@ -1075,18 +1348,18 @@ def patch_namespaced_lease_candidate_with_http_info(self, name, namespace, body,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1099,12 +1372,22 @@ def patch_namespaced_lease_candidate_with_http_info(self, name, namespace, body,
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1LeaseCandidate",
+ 201: "V1beta1LeaseCandidate",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/coordination.k8s.io/v1beta1/namespaces/{namespace}/leasecandidates/{name}', 'PATCH',
path_params,
@@ -1113,13 +1396,14 @@ def patch_namespaced_lease_candidate_with_http_info(self, name, namespace, body,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1LeaseCandidate', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_lease_candidate(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_lease_candidate # noqa: E501
@@ -1127,23 +1411,30 @@ def read_namespaced_lease_candidate(self, name, namespace, **kwargs): # noqa: E
read the specified LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_lease_candidate(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the LeaseCandidate (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the LeaseCandidate (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1LeaseCandidate
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1LeaseCandidate
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_lease_candidate_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -1154,25 +1445,38 @@ def read_namespaced_lease_candidate_with_http_info(self, name, namespace, **kwar
read the specified LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_lease_candidate_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the LeaseCandidate (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the LeaseCandidate (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1LeaseCandidate, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1LeaseCandidate, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1187,7 +1491,10 @@ def read_namespaced_lease_candidate_with_http_info(self, name, namespace, **kwar
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1200,12 +1507,10 @@ def read_namespaced_lease_candidate_with_http_info(self, name, namespace, **kwar
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_lease_candidate`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_lease_candidate`") # noqa: E501
collection_formats = {}
@@ -1217,10 +1522,10 @@ def read_namespaced_lease_candidate_with_http_info(self, name, namespace, **kwar
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1233,6 +1538,11 @@ def read_namespaced_lease_candidate_with_http_info(self, name, namespace, **kwar
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1LeaseCandidate",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/coordination.k8s.io/v1beta1/namespaces/{namespace}/leasecandidates/{name}', 'GET',
path_params,
@@ -1241,13 +1551,14 @@ def read_namespaced_lease_candidate_with_http_info(self, name, namespace, **kwar
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1LeaseCandidate', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_lease_candidate(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_lease_candidate # noqa: E501
@@ -1255,27 +1566,38 @@ def replace_namespaced_lease_candidate(self, name, namespace, body, **kwargs):
replace the specified LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_lease_candidate(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the LeaseCandidate (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1beta1LeaseCandidate body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the LeaseCandidate (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1beta1LeaseCandidate
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1beta1LeaseCandidate
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1beta1LeaseCandidate
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_lease_candidate_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -1286,29 +1608,46 @@ def replace_namespaced_lease_candidate_with_http_info(self, name, namespace, bod
replace the specified LeaseCandidate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_lease_candidate_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the LeaseCandidate (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1beta1LeaseCandidate body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the LeaseCandidate (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1beta1LeaseCandidate
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1beta1LeaseCandidate, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1beta1LeaseCandidate, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1327,7 +1666,10 @@ def replace_namespaced_lease_candidate_with_http_info(self, name, namespace, bod
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1340,16 +1682,13 @@ def replace_namespaced_lease_candidate_with_http_info(self, name, namespace, bod
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_lease_candidate`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_lease_candidate`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_lease_candidate`") # noqa: E501
collection_formats = {}
@@ -1361,16 +1700,16 @@ def replace_namespaced_lease_candidate_with_http_info(self, name, namespace, bod
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1385,6 +1724,12 @@ def replace_namespaced_lease_candidate_with_http_info(self, name, namespace, bod
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1beta1LeaseCandidate",
+ 201: "V1beta1LeaseCandidate",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/coordination.k8s.io/v1beta1/namespaces/{namespace}/leasecandidates/{name}', 'PUT',
path_params,
@@ -1393,10 +1738,11 @@ def replace_namespaced_lease_candidate_with_http_info(self, name, namespace, bod
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1beta1LeaseCandidate', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/core_api.py b/kubernetes/client/api/core_api.py
index 6026d27a28..f36b8c329b 100644
--- a/kubernetes/client/api/core_api.py
+++ b/kubernetes/client/api/core_api.py
@@ -42,20 +42,24 @@ def get_api_versions(self, **kwargs): # noqa: E501
get available API versions # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_versions(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIVersions
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIVersions
"""
kwargs['_return_http_data_only'] = True
return self.get_api_versions_with_http_info(**kwargs) # noqa: E501
@@ -66,22 +70,32 @@ def get_api_versions_with_http_info(self, **kwargs): # noqa: E501
get available API versions # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_versions_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIVersions, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIVersions, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -93,7 +107,10 @@ def get_api_versions_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -112,7 +129,7 @@ def get_api_versions_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -125,6 +142,11 @@ def get_api_versions_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIVersions",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/', 'GET',
path_params,
@@ -133,10 +155,11 @@ def get_api_versions_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIVersions', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/core_v1_api.py b/kubernetes/client/api/core_v1_api.py
index 9609abcce5..0950995bde 100644
--- a/kubernetes/client/api/core_v1_api.py
+++ b/kubernetes/client/api/core_v1_api.py
@@ -42,23 +42,30 @@ def connect_delete_namespaced_pod_proxy(self, name, namespace, **kwargs): # noq
connect DELETE requests to proxy of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_delete_namespaced_pod_proxy(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: Path is the URL path to use for the current proxy request to pod.
+ :param name: name of the PodProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: Path is the URL path to use for the current proxy request to pod.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_delete_namespaced_pod_proxy_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -69,25 +76,38 @@ def connect_delete_namespaced_pod_proxy_with_http_info(self, name, namespace, **
connect DELETE requests to proxy of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_delete_namespaced_pod_proxy_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: Path is the URL path to use for the current proxy request to pod.
+ :param name: name of the PodProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: Path is the URL path to use for the current proxy request to pod.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -102,7 +122,10 @@ def connect_delete_namespaced_pod_proxy_with_http_info(self, name, namespace, **
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -115,12 +138,10 @@ def connect_delete_namespaced_pod_proxy_with_http_info(self, name, namespace, **
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_delete_namespaced_pod_proxy`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_delete_namespaced_pod_proxy`") # noqa: E501
collection_formats = {}
@@ -132,10 +153,10 @@ def connect_delete_namespaced_pod_proxy_with_http_info(self, name, namespace, **
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'path' in local_var_params and local_var_params['path'] is not None: # noqa: E501
+ if local_var_params.get('path') is not None: # noqa: E501
query_params.append(('path', local_var_params['path'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -148,6 +169,11 @@ def connect_delete_namespaced_pod_proxy_with_http_info(self, name, namespace, **
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/proxy', 'DELETE',
path_params,
@@ -156,13 +182,14 @@ def connect_delete_namespaced_pod_proxy_with_http_info(self, name, namespace, **
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_delete_namespaced_pod_proxy_with_path(self, name, namespace, path, **kwargs): # noqa: E501
"""connect_delete_namespaced_pod_proxy_with_path # noqa: E501
@@ -170,24 +197,32 @@ def connect_delete_namespaced_pod_proxy_with_path(self, name, namespace, path, *
connect DELETE requests to proxy of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_delete_namespaced_pod_proxy_with_path(name, namespace, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the URL path to use for the current proxy request to pod.
+ :param name: name of the PodProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the URL path to use for the current proxy request to pod.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_delete_namespaced_pod_proxy_with_path_with_http_info(name, namespace, path, **kwargs) # noqa: E501
@@ -198,26 +233,40 @@ def connect_delete_namespaced_pod_proxy_with_path_with_http_info(self, name, nam
connect DELETE requests to proxy of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_delete_namespaced_pod_proxy_with_path_with_http_info(name, namespace, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the URL path to use for the current proxy request to pod.
+ :param name: name of the PodProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the URL path to use for the current proxy request to pod.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -233,7 +282,10 @@ def connect_delete_namespaced_pod_proxy_with_path_with_http_info(self, name, nam
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -246,16 +298,13 @@ def connect_delete_namespaced_pod_proxy_with_path_with_http_info(self, name, nam
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_delete_namespaced_pod_proxy_with_path`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_delete_namespaced_pod_proxy_with_path`") # noqa: E501
# verify the required parameter 'path' is set
- if self.api_client.client_side_validation and ('path' not in local_var_params or # noqa: E501
- local_var_params['path'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('path') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `path` when calling `connect_delete_namespaced_pod_proxy_with_path`") # noqa: E501
collection_formats = {}
@@ -269,10 +318,10 @@ def connect_delete_namespaced_pod_proxy_with_path_with_http_info(self, name, nam
path_params['path'] = local_var_params['path'] # noqa: E501
query_params = []
- if 'path2' in local_var_params and local_var_params['path2'] is not None: # noqa: E501
+ if local_var_params.get('path2') is not None: # noqa: E501
query_params.append(('path', local_var_params['path2'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -285,6 +334,11 @@ def connect_delete_namespaced_pod_proxy_with_path_with_http_info(self, name, nam
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/proxy/{path}', 'DELETE',
path_params,
@@ -293,13 +347,14 @@ def connect_delete_namespaced_pod_proxy_with_path_with_http_info(self, name, nam
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_delete_namespaced_service_proxy(self, name, namespace, **kwargs): # noqa: E501
"""connect_delete_namespaced_service_proxy # noqa: E501
@@ -307,23 +362,30 @@ def connect_delete_namespaced_service_proxy(self, name, namespace, **kwargs): #
connect DELETE requests to proxy of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_delete_namespaced_service_proxy(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :param name: name of the ServiceProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_delete_namespaced_service_proxy_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -334,25 +396,38 @@ def connect_delete_namespaced_service_proxy_with_http_info(self, name, namespace
connect DELETE requests to proxy of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_delete_namespaced_service_proxy_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :param name: name of the ServiceProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -367,7 +442,10 @@ def connect_delete_namespaced_service_proxy_with_http_info(self, name, namespace
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -380,12 +458,10 @@ def connect_delete_namespaced_service_proxy_with_http_info(self, name, namespace
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_delete_namespaced_service_proxy`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_delete_namespaced_service_proxy`") # noqa: E501
collection_formats = {}
@@ -397,10 +473,10 @@ def connect_delete_namespaced_service_proxy_with_http_info(self, name, namespace
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'path' in local_var_params and local_var_params['path'] is not None: # noqa: E501
+ if local_var_params.get('path') is not None: # noqa: E501
query_params.append(('path', local_var_params['path'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -413,6 +489,11 @@ def connect_delete_namespaced_service_proxy_with_http_info(self, name, namespace
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/services/{name}/proxy', 'DELETE',
path_params,
@@ -421,13 +502,14 @@ def connect_delete_namespaced_service_proxy_with_http_info(self, name, namespace
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_delete_namespaced_service_proxy_with_path(self, name, namespace, path, **kwargs): # noqa: E501
"""connect_delete_namespaced_service_proxy_with_path # noqa: E501
@@ -435,24 +517,32 @@ def connect_delete_namespaced_service_proxy_with_path(self, name, namespace, pat
connect DELETE requests to proxy of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_delete_namespaced_service_proxy_with_path(name, namespace, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :param name: name of the ServiceProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_delete_namespaced_service_proxy_with_path_with_http_info(name, namespace, path, **kwargs) # noqa: E501
@@ -463,26 +553,40 @@ def connect_delete_namespaced_service_proxy_with_path_with_http_info(self, name,
connect DELETE requests to proxy of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_delete_namespaced_service_proxy_with_path_with_http_info(name, namespace, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :param name: name of the ServiceProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -498,7 +602,10 @@ def connect_delete_namespaced_service_proxy_with_path_with_http_info(self, name,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -511,16 +618,13 @@ def connect_delete_namespaced_service_proxy_with_path_with_http_info(self, name,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_delete_namespaced_service_proxy_with_path`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_delete_namespaced_service_proxy_with_path`") # noqa: E501
# verify the required parameter 'path' is set
- if self.api_client.client_side_validation and ('path' not in local_var_params or # noqa: E501
- local_var_params['path'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('path') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `path` when calling `connect_delete_namespaced_service_proxy_with_path`") # noqa: E501
collection_formats = {}
@@ -534,10 +638,10 @@ def connect_delete_namespaced_service_proxy_with_path_with_http_info(self, name,
path_params['path'] = local_var_params['path'] # noqa: E501
query_params = []
- if 'path2' in local_var_params and local_var_params['path2'] is not None: # noqa: E501
+ if local_var_params.get('path2') is not None: # noqa: E501
query_params.append(('path', local_var_params['path2'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -550,6 +654,11 @@ def connect_delete_namespaced_service_proxy_with_path_with_http_info(self, name,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/services/{name}/proxy/{path}', 'DELETE',
path_params,
@@ -558,13 +667,14 @@ def connect_delete_namespaced_service_proxy_with_path_with_http_info(self, name,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_delete_node_proxy(self, name, **kwargs): # noqa: E501
"""connect_delete_node_proxy # noqa: E501
@@ -572,22 +682,28 @@ def connect_delete_node_proxy(self, name, **kwargs): # noqa: E501
connect DELETE requests to proxy of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_delete_node_proxy(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the NodeProxyOptions (required)
- :param str path: Path is the URL path to use for the current proxy request to node.
+ :param name: name of the NodeProxyOptions (required)
+ :type name: str
+ :param path: Path is the URL path to use for the current proxy request to node.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_delete_node_proxy_with_http_info(name, **kwargs) # noqa: E501
@@ -598,24 +714,36 @@ def connect_delete_node_proxy_with_http_info(self, name, **kwargs): # noqa: E50
connect DELETE requests to proxy of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_delete_node_proxy_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the NodeProxyOptions (required)
- :param str path: Path is the URL path to use for the current proxy request to node.
+ :param name: name of the NodeProxyOptions (required)
+ :type name: str
+ :param path: Path is the URL path to use for the current proxy request to node.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -629,7 +757,10 @@ def connect_delete_node_proxy_with_http_info(self, name, **kwargs): # noqa: E50
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -642,8 +773,7 @@ def connect_delete_node_proxy_with_http_info(self, name, **kwargs): # noqa: E50
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_delete_node_proxy`") # noqa: E501
collection_formats = {}
@@ -653,10 +783,10 @@ def connect_delete_node_proxy_with_http_info(self, name, **kwargs): # noqa: E50
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'path' in local_var_params and local_var_params['path'] is not None: # noqa: E501
+ if local_var_params.get('path') is not None: # noqa: E501
query_params.append(('path', local_var_params['path'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -669,6 +799,11 @@ def connect_delete_node_proxy_with_http_info(self, name, **kwargs): # noqa: E50
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/nodes/{name}/proxy', 'DELETE',
path_params,
@@ -677,13 +812,14 @@ def connect_delete_node_proxy_with_http_info(self, name, **kwargs): # noqa: E50
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_delete_node_proxy_with_path(self, name, path, **kwargs): # noqa: E501
"""connect_delete_node_proxy_with_path # noqa: E501
@@ -691,23 +827,30 @@ def connect_delete_node_proxy_with_path(self, name, path, **kwargs): # noqa: E5
connect DELETE requests to proxy of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_delete_node_proxy_with_path(name, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the NodeProxyOptions (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the URL path to use for the current proxy request to node.
+ :param name: name of the NodeProxyOptions (required)
+ :type name: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the URL path to use for the current proxy request to node.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_delete_node_proxy_with_path_with_http_info(name, path, **kwargs) # noqa: E501
@@ -718,25 +861,38 @@ def connect_delete_node_proxy_with_path_with_http_info(self, name, path, **kwarg
connect DELETE requests to proxy of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_delete_node_proxy_with_path_with_http_info(name, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the NodeProxyOptions (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the URL path to use for the current proxy request to node.
+ :param name: name of the NodeProxyOptions (required)
+ :type name: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the URL path to use for the current proxy request to node.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -751,7 +907,10 @@ def connect_delete_node_proxy_with_path_with_http_info(self, name, path, **kwarg
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -764,12 +923,10 @@ def connect_delete_node_proxy_with_path_with_http_info(self, name, path, **kwarg
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_delete_node_proxy_with_path`") # noqa: E501
# verify the required parameter 'path' is set
- if self.api_client.client_side_validation and ('path' not in local_var_params or # noqa: E501
- local_var_params['path'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('path') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `path` when calling `connect_delete_node_proxy_with_path`") # noqa: E501
collection_formats = {}
@@ -781,10 +938,10 @@ def connect_delete_node_proxy_with_path_with_http_info(self, name, path, **kwarg
path_params['path'] = local_var_params['path'] # noqa: E501
query_params = []
- if 'path2' in local_var_params and local_var_params['path2'] is not None: # noqa: E501
+ if local_var_params.get('path2') is not None: # noqa: E501
query_params.append(('path', local_var_params['path2'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -797,6 +954,11 @@ def connect_delete_node_proxy_with_path_with_http_info(self, name, path, **kwarg
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/nodes/{name}/proxy/{path}', 'DELETE',
path_params,
@@ -805,13 +967,14 @@ def connect_delete_node_proxy_with_path_with_http_info(self, name, path, **kwarg
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_get_namespaced_pod_attach(self, name, namespace, **kwargs): # noqa: E501
"""connect_get_namespaced_pod_attach # noqa: E501
@@ -819,27 +982,38 @@ def connect_get_namespaced_pod_attach(self, name, namespace, **kwargs): # noqa:
connect GET requests to attach of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_get_namespaced_pod_attach(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodAttachOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str container: The container in which to execute the command. Defaults to only container if there is only one container in the pod.
- :param bool stderr: Stderr if true indicates that stderr is to be redirected for the attach call. Defaults to true.
- :param bool stdin: Stdin if true, redirects the standard input stream of the pod for this call. Defaults to false.
- :param bool stdout: Stdout if true indicates that stdout is to be redirected for the attach call. Defaults to true.
- :param bool tty: TTY if true indicates that a tty will be allocated for the attach call. This is passed through the container runtime so the tty is allocated on the worker node by the container runtime. Defaults to false.
+ :param name: name of the PodAttachOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param container: The container in which to execute the command. Defaults to only container if there is only one container in the pod.
+ :type container: str
+ :param stderr: Stderr if true indicates that stderr is to be redirected for the attach call. Defaults to true.
+ :type stderr: bool
+ :param stdin: Stdin if true, redirects the standard input stream of the pod for this call. Defaults to false.
+ :type stdin: bool
+ :param stdout: Stdout if true indicates that stdout is to be redirected for the attach call. Defaults to true.
+ :type stdout: bool
+ :param tty: TTY if true indicates that a tty will be allocated for the attach call. This is passed through the container runtime so the tty is allocated on the worker node by the container runtime. Defaults to false.
+ :type tty: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_get_namespaced_pod_attach_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -850,29 +1024,46 @@ def connect_get_namespaced_pod_attach_with_http_info(self, name, namespace, **kw
connect GET requests to attach of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_get_namespaced_pod_attach_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodAttachOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str container: The container in which to execute the command. Defaults to only container if there is only one container in the pod.
- :param bool stderr: Stderr if true indicates that stderr is to be redirected for the attach call. Defaults to true.
- :param bool stdin: Stdin if true, redirects the standard input stream of the pod for this call. Defaults to false.
- :param bool stdout: Stdout if true indicates that stdout is to be redirected for the attach call. Defaults to true.
- :param bool tty: TTY if true indicates that a tty will be allocated for the attach call. This is passed through the container runtime so the tty is allocated on the worker node by the container runtime. Defaults to false.
+ :param name: name of the PodAttachOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param container: The container in which to execute the command. Defaults to only container if there is only one container in the pod.
+ :type container: str
+ :param stderr: Stderr if true indicates that stderr is to be redirected for the attach call. Defaults to true.
+ :type stderr: bool
+ :param stdin: Stdin if true, redirects the standard input stream of the pod for this call. Defaults to false.
+ :type stdin: bool
+ :param stdout: Stdout if true indicates that stdout is to be redirected for the attach call. Defaults to true.
+ :type stdout: bool
+ :param tty: TTY if true indicates that a tty will be allocated for the attach call. This is passed through the container runtime so the tty is allocated on the worker node by the container runtime. Defaults to false.
+ :type tty: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -891,7 +1082,10 @@ def connect_get_namespaced_pod_attach_with_http_info(self, name, namespace, **kw
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -904,12 +1098,10 @@ def connect_get_namespaced_pod_attach_with_http_info(self, name, namespace, **kw
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_get_namespaced_pod_attach`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_get_namespaced_pod_attach`") # noqa: E501
collection_formats = {}
@@ -921,18 +1113,18 @@ def connect_get_namespaced_pod_attach_with_http_info(self, name, namespace, **kw
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'container' in local_var_params and local_var_params['container'] is not None: # noqa: E501
+ if local_var_params.get('container') is not None: # noqa: E501
query_params.append(('container', local_var_params['container'])) # noqa: E501
- if 'stderr' in local_var_params and local_var_params['stderr'] is not None: # noqa: E501
+ if local_var_params.get('stderr') is not None: # noqa: E501
query_params.append(('stderr', local_var_params['stderr'])) # noqa: E501
- if 'stdin' in local_var_params and local_var_params['stdin'] is not None: # noqa: E501
+ if local_var_params.get('stdin') is not None: # noqa: E501
query_params.append(('stdin', local_var_params['stdin'])) # noqa: E501
- if 'stdout' in local_var_params and local_var_params['stdout'] is not None: # noqa: E501
+ if local_var_params.get('stdout') is not None: # noqa: E501
query_params.append(('stdout', local_var_params['stdout'])) # noqa: E501
- if 'tty' in local_var_params and local_var_params['tty'] is not None: # noqa: E501
+ if local_var_params.get('tty') is not None: # noqa: E501
query_params.append(('tty', local_var_params['tty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -945,6 +1137,11 @@ def connect_get_namespaced_pod_attach_with_http_info(self, name, namespace, **kw
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/attach', 'GET',
path_params,
@@ -953,13 +1150,14 @@ def connect_get_namespaced_pod_attach_with_http_info(self, name, namespace, **kw
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_get_namespaced_pod_exec(self, name, namespace, **kwargs): # noqa: E501
"""connect_get_namespaced_pod_exec # noqa: E501
@@ -967,28 +1165,40 @@ def connect_get_namespaced_pod_exec(self, name, namespace, **kwargs): # noqa: E
connect GET requests to exec of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_get_namespaced_pod_exec(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodExecOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str command: Command is the remote command to execute. argv array. Not executed within a shell.
- :param str container: Container in which to execute the command. Defaults to only container if there is only one container in the pod.
- :param bool stderr: Redirect the standard error stream of the pod for this call.
- :param bool stdin: Redirect the standard input stream of the pod for this call. Defaults to false.
- :param bool stdout: Redirect the standard output stream of the pod for this call.
- :param bool tty: TTY if true indicates that a tty will be allocated for the exec call. Defaults to false.
+ :param name: name of the PodExecOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param command: Command is the remote command to execute. argv array. Not executed within a shell.
+ :type command: str
+ :param container: Container in which to execute the command. Defaults to only container if there is only one container in the pod.
+ :type container: str
+ :param stderr: Redirect the standard error stream of the pod for this call.
+ :type stderr: bool
+ :param stdin: Redirect the standard input stream of the pod for this call. Defaults to false.
+ :type stdin: bool
+ :param stdout: Redirect the standard output stream of the pod for this call.
+ :type stdout: bool
+ :param tty: TTY if true indicates that a tty will be allocated for the exec call. Defaults to false.
+ :type tty: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_get_namespaced_pod_exec_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -999,30 +1209,48 @@ def connect_get_namespaced_pod_exec_with_http_info(self, name, namespace, **kwar
connect GET requests to exec of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_get_namespaced_pod_exec_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodExecOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str command: Command is the remote command to execute. argv array. Not executed within a shell.
- :param str container: Container in which to execute the command. Defaults to only container if there is only one container in the pod.
- :param bool stderr: Redirect the standard error stream of the pod for this call.
- :param bool stdin: Redirect the standard input stream of the pod for this call. Defaults to false.
- :param bool stdout: Redirect the standard output stream of the pod for this call.
- :param bool tty: TTY if true indicates that a tty will be allocated for the exec call. Defaults to false.
+ :param name: name of the PodExecOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param command: Command is the remote command to execute. argv array. Not executed within a shell.
+ :type command: str
+ :param container: Container in which to execute the command. Defaults to only container if there is only one container in the pod.
+ :type container: str
+ :param stderr: Redirect the standard error stream of the pod for this call.
+ :type stderr: bool
+ :param stdin: Redirect the standard input stream of the pod for this call. Defaults to false.
+ :type stdin: bool
+ :param stdout: Redirect the standard output stream of the pod for this call.
+ :type stdout: bool
+ :param tty: TTY if true indicates that a tty will be allocated for the exec call. Defaults to false.
+ :type tty: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1042,7 +1270,10 @@ def connect_get_namespaced_pod_exec_with_http_info(self, name, namespace, **kwar
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1055,12 +1286,10 @@ def connect_get_namespaced_pod_exec_with_http_info(self, name, namespace, **kwar
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_get_namespaced_pod_exec`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_get_namespaced_pod_exec`") # noqa: E501
collection_formats = {}
@@ -1072,20 +1301,20 @@ def connect_get_namespaced_pod_exec_with_http_info(self, name, namespace, **kwar
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'command' in local_var_params and local_var_params['command'] is not None: # noqa: E501
+ if local_var_params.get('command') is not None: # noqa: E501
query_params.append(('command', local_var_params['command'])) # noqa: E501
- if 'container' in local_var_params and local_var_params['container'] is not None: # noqa: E501
+ if local_var_params.get('container') is not None: # noqa: E501
query_params.append(('container', local_var_params['container'])) # noqa: E501
- if 'stderr' in local_var_params and local_var_params['stderr'] is not None: # noqa: E501
+ if local_var_params.get('stderr') is not None: # noqa: E501
query_params.append(('stderr', local_var_params['stderr'])) # noqa: E501
- if 'stdin' in local_var_params and local_var_params['stdin'] is not None: # noqa: E501
+ if local_var_params.get('stdin') is not None: # noqa: E501
query_params.append(('stdin', local_var_params['stdin'])) # noqa: E501
- if 'stdout' in local_var_params and local_var_params['stdout'] is not None: # noqa: E501
+ if local_var_params.get('stdout') is not None: # noqa: E501
query_params.append(('stdout', local_var_params['stdout'])) # noqa: E501
- if 'tty' in local_var_params and local_var_params['tty'] is not None: # noqa: E501
+ if local_var_params.get('tty') is not None: # noqa: E501
query_params.append(('tty', local_var_params['tty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1098,6 +1327,11 @@ def connect_get_namespaced_pod_exec_with_http_info(self, name, namespace, **kwar
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/exec', 'GET',
path_params,
@@ -1106,13 +1340,14 @@ def connect_get_namespaced_pod_exec_with_http_info(self, name, namespace, **kwar
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_get_namespaced_pod_portforward(self, name, namespace, **kwargs): # noqa: E501
"""connect_get_namespaced_pod_portforward # noqa: E501
@@ -1120,23 +1355,30 @@ def connect_get_namespaced_pod_portforward(self, name, namespace, **kwargs): #
connect GET requests to portforward of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_get_namespaced_pod_portforward(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodPortForwardOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param int ports: List of ports to forward Required when using WebSockets
+ :param name: name of the PodPortForwardOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param ports: List of ports to forward Required when using WebSockets
+ :type ports: int
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_get_namespaced_pod_portforward_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -1147,25 +1389,38 @@ def connect_get_namespaced_pod_portforward_with_http_info(self, name, namespace,
connect GET requests to portforward of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_get_namespaced_pod_portforward_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodPortForwardOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param int ports: List of ports to forward Required when using WebSockets
+ :param name: name of the PodPortForwardOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param ports: List of ports to forward Required when using WebSockets
+ :type ports: int
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1180,7 +1435,10 @@ def connect_get_namespaced_pod_portforward_with_http_info(self, name, namespace,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1193,12 +1451,10 @@ def connect_get_namespaced_pod_portforward_with_http_info(self, name, namespace,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_get_namespaced_pod_portforward`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_get_namespaced_pod_portforward`") # noqa: E501
collection_formats = {}
@@ -1210,10 +1466,10 @@ def connect_get_namespaced_pod_portforward_with_http_info(self, name, namespace,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'ports' in local_var_params and local_var_params['ports'] is not None: # noqa: E501
+ if local_var_params.get('ports') is not None: # noqa: E501
query_params.append(('ports', local_var_params['ports'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1226,6 +1482,11 @@ def connect_get_namespaced_pod_portforward_with_http_info(self, name, namespace,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/portforward', 'GET',
path_params,
@@ -1234,13 +1495,14 @@ def connect_get_namespaced_pod_portforward_with_http_info(self, name, namespace,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_get_namespaced_pod_proxy(self, name, namespace, **kwargs): # noqa: E501
"""connect_get_namespaced_pod_proxy # noqa: E501
@@ -1248,23 +1510,30 @@ def connect_get_namespaced_pod_proxy(self, name, namespace, **kwargs): # noqa:
connect GET requests to proxy of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_get_namespaced_pod_proxy(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: Path is the URL path to use for the current proxy request to pod.
+ :param name: name of the PodProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: Path is the URL path to use for the current proxy request to pod.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_get_namespaced_pod_proxy_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -1275,25 +1544,38 @@ def connect_get_namespaced_pod_proxy_with_http_info(self, name, namespace, **kwa
connect GET requests to proxy of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_get_namespaced_pod_proxy_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: Path is the URL path to use for the current proxy request to pod.
+ :param name: name of the PodProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: Path is the URL path to use for the current proxy request to pod.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1308,7 +1590,10 @@ def connect_get_namespaced_pod_proxy_with_http_info(self, name, namespace, **kwa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1321,12 +1606,10 @@ def connect_get_namespaced_pod_proxy_with_http_info(self, name, namespace, **kwa
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_get_namespaced_pod_proxy`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_get_namespaced_pod_proxy`") # noqa: E501
collection_formats = {}
@@ -1338,10 +1621,10 @@ def connect_get_namespaced_pod_proxy_with_http_info(self, name, namespace, **kwa
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'path' in local_var_params and local_var_params['path'] is not None: # noqa: E501
+ if local_var_params.get('path') is not None: # noqa: E501
query_params.append(('path', local_var_params['path'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1354,6 +1637,11 @@ def connect_get_namespaced_pod_proxy_with_http_info(self, name, namespace, **kwa
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/proxy', 'GET',
path_params,
@@ -1362,13 +1650,14 @@ def connect_get_namespaced_pod_proxy_with_http_info(self, name, namespace, **kwa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_get_namespaced_pod_proxy_with_path(self, name, namespace, path, **kwargs): # noqa: E501
"""connect_get_namespaced_pod_proxy_with_path # noqa: E501
@@ -1376,24 +1665,32 @@ def connect_get_namespaced_pod_proxy_with_path(self, name, namespace, path, **kw
connect GET requests to proxy of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_get_namespaced_pod_proxy_with_path(name, namespace, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the URL path to use for the current proxy request to pod.
+ :param name: name of the PodProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the URL path to use for the current proxy request to pod.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_get_namespaced_pod_proxy_with_path_with_http_info(name, namespace, path, **kwargs) # noqa: E501
@@ -1404,26 +1701,40 @@ def connect_get_namespaced_pod_proxy_with_path_with_http_info(self, name, namesp
connect GET requests to proxy of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_get_namespaced_pod_proxy_with_path_with_http_info(name, namespace, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the URL path to use for the current proxy request to pod.
+ :param name: name of the PodProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the URL path to use for the current proxy request to pod.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1439,7 +1750,10 @@ def connect_get_namespaced_pod_proxy_with_path_with_http_info(self, name, namesp
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1452,16 +1766,13 @@ def connect_get_namespaced_pod_proxy_with_path_with_http_info(self, name, namesp
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_get_namespaced_pod_proxy_with_path`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_get_namespaced_pod_proxy_with_path`") # noqa: E501
# verify the required parameter 'path' is set
- if self.api_client.client_side_validation and ('path' not in local_var_params or # noqa: E501
- local_var_params['path'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('path') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `path` when calling `connect_get_namespaced_pod_proxy_with_path`") # noqa: E501
collection_formats = {}
@@ -1475,10 +1786,10 @@ def connect_get_namespaced_pod_proxy_with_path_with_http_info(self, name, namesp
path_params['path'] = local_var_params['path'] # noqa: E501
query_params = []
- if 'path2' in local_var_params and local_var_params['path2'] is not None: # noqa: E501
+ if local_var_params.get('path2') is not None: # noqa: E501
query_params.append(('path', local_var_params['path2'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1491,6 +1802,11 @@ def connect_get_namespaced_pod_proxy_with_path_with_http_info(self, name, namesp
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/proxy/{path}', 'GET',
path_params,
@@ -1499,13 +1815,14 @@ def connect_get_namespaced_pod_proxy_with_path_with_http_info(self, name, namesp
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_get_namespaced_service_proxy(self, name, namespace, **kwargs): # noqa: E501
"""connect_get_namespaced_service_proxy # noqa: E501
@@ -1513,23 +1830,30 @@ def connect_get_namespaced_service_proxy(self, name, namespace, **kwargs): # no
connect GET requests to proxy of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_get_namespaced_service_proxy(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :param name: name of the ServiceProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_get_namespaced_service_proxy_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -1540,25 +1864,38 @@ def connect_get_namespaced_service_proxy_with_http_info(self, name, namespace, *
connect GET requests to proxy of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_get_namespaced_service_proxy_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :param name: name of the ServiceProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1573,7 +1910,10 @@ def connect_get_namespaced_service_proxy_with_http_info(self, name, namespace, *
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1586,12 +1926,10 @@ def connect_get_namespaced_service_proxy_with_http_info(self, name, namespace, *
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_get_namespaced_service_proxy`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_get_namespaced_service_proxy`") # noqa: E501
collection_formats = {}
@@ -1603,10 +1941,10 @@ def connect_get_namespaced_service_proxy_with_http_info(self, name, namespace, *
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'path' in local_var_params and local_var_params['path'] is not None: # noqa: E501
+ if local_var_params.get('path') is not None: # noqa: E501
query_params.append(('path', local_var_params['path'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1619,6 +1957,11 @@ def connect_get_namespaced_service_proxy_with_http_info(self, name, namespace, *
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/services/{name}/proxy', 'GET',
path_params,
@@ -1627,13 +1970,14 @@ def connect_get_namespaced_service_proxy_with_http_info(self, name, namespace, *
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_get_namespaced_service_proxy_with_path(self, name, namespace, path, **kwargs): # noqa: E501
"""connect_get_namespaced_service_proxy_with_path # noqa: E501
@@ -1641,24 +1985,32 @@ def connect_get_namespaced_service_proxy_with_path(self, name, namespace, path,
connect GET requests to proxy of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_get_namespaced_service_proxy_with_path(name, namespace, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :param name: name of the ServiceProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_get_namespaced_service_proxy_with_path_with_http_info(name, namespace, path, **kwargs) # noqa: E501
@@ -1669,26 +2021,40 @@ def connect_get_namespaced_service_proxy_with_path_with_http_info(self, name, na
connect GET requests to proxy of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_get_namespaced_service_proxy_with_path_with_http_info(name, namespace, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :param name: name of the ServiceProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1704,7 +2070,10 @@ def connect_get_namespaced_service_proxy_with_path_with_http_info(self, name, na
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1717,16 +2086,13 @@ def connect_get_namespaced_service_proxy_with_path_with_http_info(self, name, na
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_get_namespaced_service_proxy_with_path`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_get_namespaced_service_proxy_with_path`") # noqa: E501
# verify the required parameter 'path' is set
- if self.api_client.client_side_validation and ('path' not in local_var_params or # noqa: E501
- local_var_params['path'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('path') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `path` when calling `connect_get_namespaced_service_proxy_with_path`") # noqa: E501
collection_formats = {}
@@ -1740,10 +2106,10 @@ def connect_get_namespaced_service_proxy_with_path_with_http_info(self, name, na
path_params['path'] = local_var_params['path'] # noqa: E501
query_params = []
- if 'path2' in local_var_params and local_var_params['path2'] is not None: # noqa: E501
+ if local_var_params.get('path2') is not None: # noqa: E501
query_params.append(('path', local_var_params['path2'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1756,6 +2122,11 @@ def connect_get_namespaced_service_proxy_with_path_with_http_info(self, name, na
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/services/{name}/proxy/{path}', 'GET',
path_params,
@@ -1764,13 +2135,14 @@ def connect_get_namespaced_service_proxy_with_path_with_http_info(self, name, na
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_get_node_proxy(self, name, **kwargs): # noqa: E501
"""connect_get_node_proxy # noqa: E501
@@ -1778,22 +2150,28 @@ def connect_get_node_proxy(self, name, **kwargs): # noqa: E501
connect GET requests to proxy of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_get_node_proxy(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the NodeProxyOptions (required)
- :param str path: Path is the URL path to use for the current proxy request to node.
+ :param name: name of the NodeProxyOptions (required)
+ :type name: str
+ :param path: Path is the URL path to use for the current proxy request to node.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_get_node_proxy_with_http_info(name, **kwargs) # noqa: E501
@@ -1804,24 +2182,36 @@ def connect_get_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
connect GET requests to proxy of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_get_node_proxy_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the NodeProxyOptions (required)
- :param str path: Path is the URL path to use for the current proxy request to node.
+ :param name: name of the NodeProxyOptions (required)
+ :type name: str
+ :param path: Path is the URL path to use for the current proxy request to node.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1835,7 +2225,10 @@ def connect_get_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1848,8 +2241,7 @@ def connect_get_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_get_node_proxy`") # noqa: E501
collection_formats = {}
@@ -1859,10 +2251,10 @@ def connect_get_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'path' in local_var_params and local_var_params['path'] is not None: # noqa: E501
+ if local_var_params.get('path') is not None: # noqa: E501
query_params.append(('path', local_var_params['path'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1875,6 +2267,11 @@ def connect_get_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/nodes/{name}/proxy', 'GET',
path_params,
@@ -1883,13 +2280,14 @@ def connect_get_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_get_node_proxy_with_path(self, name, path, **kwargs): # noqa: E501
"""connect_get_node_proxy_with_path # noqa: E501
@@ -1897,23 +2295,30 @@ def connect_get_node_proxy_with_path(self, name, path, **kwargs): # noqa: E501
connect GET requests to proxy of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_get_node_proxy_with_path(name, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the NodeProxyOptions (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the URL path to use for the current proxy request to node.
+ :param name: name of the NodeProxyOptions (required)
+ :type name: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the URL path to use for the current proxy request to node.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_get_node_proxy_with_path_with_http_info(name, path, **kwargs) # noqa: E501
@@ -1924,25 +2329,38 @@ def connect_get_node_proxy_with_path_with_http_info(self, name, path, **kwargs):
connect GET requests to proxy of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_get_node_proxy_with_path_with_http_info(name, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the NodeProxyOptions (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the URL path to use for the current proxy request to node.
+ :param name: name of the NodeProxyOptions (required)
+ :type name: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the URL path to use for the current proxy request to node.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1957,7 +2375,10 @@ def connect_get_node_proxy_with_path_with_http_info(self, name, path, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1970,12 +2391,10 @@ def connect_get_node_proxy_with_path_with_http_info(self, name, path, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_get_node_proxy_with_path`") # noqa: E501
# verify the required parameter 'path' is set
- if self.api_client.client_side_validation and ('path' not in local_var_params or # noqa: E501
- local_var_params['path'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('path') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `path` when calling `connect_get_node_proxy_with_path`") # noqa: E501
collection_formats = {}
@@ -1987,10 +2406,10 @@ def connect_get_node_proxy_with_path_with_http_info(self, name, path, **kwargs):
path_params['path'] = local_var_params['path'] # noqa: E501
query_params = []
- if 'path2' in local_var_params and local_var_params['path2'] is not None: # noqa: E501
+ if local_var_params.get('path2') is not None: # noqa: E501
query_params.append(('path', local_var_params['path2'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2003,6 +2422,11 @@ def connect_get_node_proxy_with_path_with_http_info(self, name, path, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/nodes/{name}/proxy/{path}', 'GET',
path_params,
@@ -2011,13 +2435,14 @@ def connect_get_node_proxy_with_path_with_http_info(self, name, path, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_head_namespaced_pod_proxy(self, name, namespace, **kwargs): # noqa: E501
"""connect_head_namespaced_pod_proxy # noqa: E501
@@ -2025,23 +2450,30 @@ def connect_head_namespaced_pod_proxy(self, name, namespace, **kwargs): # noqa:
connect HEAD requests to proxy of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_head_namespaced_pod_proxy(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: Path is the URL path to use for the current proxy request to pod.
+ :param name: name of the PodProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: Path is the URL path to use for the current proxy request to pod.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_head_namespaced_pod_proxy_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -2052,25 +2484,38 @@ def connect_head_namespaced_pod_proxy_with_http_info(self, name, namespace, **kw
connect HEAD requests to proxy of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_head_namespaced_pod_proxy_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: Path is the URL path to use for the current proxy request to pod.
+ :param name: name of the PodProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: Path is the URL path to use for the current proxy request to pod.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2085,7 +2530,10 @@ def connect_head_namespaced_pod_proxy_with_http_info(self, name, namespace, **kw
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2098,12 +2546,10 @@ def connect_head_namespaced_pod_proxy_with_http_info(self, name, namespace, **kw
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_head_namespaced_pod_proxy`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_head_namespaced_pod_proxy`") # noqa: E501
collection_formats = {}
@@ -2115,10 +2561,10 @@ def connect_head_namespaced_pod_proxy_with_http_info(self, name, namespace, **kw
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'path' in local_var_params and local_var_params['path'] is not None: # noqa: E501
+ if local_var_params.get('path') is not None: # noqa: E501
query_params.append(('path', local_var_params['path'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2131,6 +2577,11 @@ def connect_head_namespaced_pod_proxy_with_http_info(self, name, namespace, **kw
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/proxy', 'HEAD',
path_params,
@@ -2139,13 +2590,14 @@ def connect_head_namespaced_pod_proxy_with_http_info(self, name, namespace, **kw
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_head_namespaced_pod_proxy_with_path(self, name, namespace, path, **kwargs): # noqa: E501
"""connect_head_namespaced_pod_proxy_with_path # noqa: E501
@@ -2153,24 +2605,32 @@ def connect_head_namespaced_pod_proxy_with_path(self, name, namespace, path, **k
connect HEAD requests to proxy of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_head_namespaced_pod_proxy_with_path(name, namespace, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the URL path to use for the current proxy request to pod.
+ :param name: name of the PodProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the URL path to use for the current proxy request to pod.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_head_namespaced_pod_proxy_with_path_with_http_info(name, namespace, path, **kwargs) # noqa: E501
@@ -2181,26 +2641,40 @@ def connect_head_namespaced_pod_proxy_with_path_with_http_info(self, name, names
connect HEAD requests to proxy of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_head_namespaced_pod_proxy_with_path_with_http_info(name, namespace, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the URL path to use for the current proxy request to pod.
+ :param name: name of the PodProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the URL path to use for the current proxy request to pod.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2216,7 +2690,10 @@ def connect_head_namespaced_pod_proxy_with_path_with_http_info(self, name, names
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2229,16 +2706,13 @@ def connect_head_namespaced_pod_proxy_with_path_with_http_info(self, name, names
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_head_namespaced_pod_proxy_with_path`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_head_namespaced_pod_proxy_with_path`") # noqa: E501
# verify the required parameter 'path' is set
- if self.api_client.client_side_validation and ('path' not in local_var_params or # noqa: E501
- local_var_params['path'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('path') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `path` when calling `connect_head_namespaced_pod_proxy_with_path`") # noqa: E501
collection_formats = {}
@@ -2252,10 +2726,10 @@ def connect_head_namespaced_pod_proxy_with_path_with_http_info(self, name, names
path_params['path'] = local_var_params['path'] # noqa: E501
query_params = []
- if 'path2' in local_var_params and local_var_params['path2'] is not None: # noqa: E501
+ if local_var_params.get('path2') is not None: # noqa: E501
query_params.append(('path', local_var_params['path2'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2268,6 +2742,11 @@ def connect_head_namespaced_pod_proxy_with_path_with_http_info(self, name, names
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/proxy/{path}', 'HEAD',
path_params,
@@ -2276,13 +2755,14 @@ def connect_head_namespaced_pod_proxy_with_path_with_http_info(self, name, names
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_head_namespaced_service_proxy(self, name, namespace, **kwargs): # noqa: E501
"""connect_head_namespaced_service_proxy # noqa: E501
@@ -2290,23 +2770,30 @@ def connect_head_namespaced_service_proxy(self, name, namespace, **kwargs): # n
connect HEAD requests to proxy of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_head_namespaced_service_proxy(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :param name: name of the ServiceProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_head_namespaced_service_proxy_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -2317,25 +2804,38 @@ def connect_head_namespaced_service_proxy_with_http_info(self, name, namespace,
connect HEAD requests to proxy of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_head_namespaced_service_proxy_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :param name: name of the ServiceProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2350,7 +2850,10 @@ def connect_head_namespaced_service_proxy_with_http_info(self, name, namespace,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2363,12 +2866,10 @@ def connect_head_namespaced_service_proxy_with_http_info(self, name, namespace,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_head_namespaced_service_proxy`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_head_namespaced_service_proxy`") # noqa: E501
collection_formats = {}
@@ -2380,10 +2881,10 @@ def connect_head_namespaced_service_proxy_with_http_info(self, name, namespace,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'path' in local_var_params and local_var_params['path'] is not None: # noqa: E501
+ if local_var_params.get('path') is not None: # noqa: E501
query_params.append(('path', local_var_params['path'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2396,6 +2897,11 @@ def connect_head_namespaced_service_proxy_with_http_info(self, name, namespace,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/services/{name}/proxy', 'HEAD',
path_params,
@@ -2404,13 +2910,14 @@ def connect_head_namespaced_service_proxy_with_http_info(self, name, namespace,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_head_namespaced_service_proxy_with_path(self, name, namespace, path, **kwargs): # noqa: E501
"""connect_head_namespaced_service_proxy_with_path # noqa: E501
@@ -2418,24 +2925,32 @@ def connect_head_namespaced_service_proxy_with_path(self, name, namespace, path,
connect HEAD requests to proxy of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_head_namespaced_service_proxy_with_path(name, namespace, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :param name: name of the ServiceProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_head_namespaced_service_proxy_with_path_with_http_info(name, namespace, path, **kwargs) # noqa: E501
@@ -2446,26 +2961,40 @@ def connect_head_namespaced_service_proxy_with_path_with_http_info(self, name, n
connect HEAD requests to proxy of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_head_namespaced_service_proxy_with_path_with_http_info(name, namespace, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :param name: name of the ServiceProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2481,7 +3010,10 @@ def connect_head_namespaced_service_proxy_with_path_with_http_info(self, name, n
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2494,16 +3026,13 @@ def connect_head_namespaced_service_proxy_with_path_with_http_info(self, name, n
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_head_namespaced_service_proxy_with_path`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_head_namespaced_service_proxy_with_path`") # noqa: E501
# verify the required parameter 'path' is set
- if self.api_client.client_side_validation and ('path' not in local_var_params or # noqa: E501
- local_var_params['path'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('path') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `path` when calling `connect_head_namespaced_service_proxy_with_path`") # noqa: E501
collection_formats = {}
@@ -2517,10 +3046,10 @@ def connect_head_namespaced_service_proxy_with_path_with_http_info(self, name, n
path_params['path'] = local_var_params['path'] # noqa: E501
query_params = []
- if 'path2' in local_var_params and local_var_params['path2'] is not None: # noqa: E501
+ if local_var_params.get('path2') is not None: # noqa: E501
query_params.append(('path', local_var_params['path2'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2533,6 +3062,11 @@ def connect_head_namespaced_service_proxy_with_path_with_http_info(self, name, n
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/services/{name}/proxy/{path}', 'HEAD',
path_params,
@@ -2541,13 +3075,14 @@ def connect_head_namespaced_service_proxy_with_path_with_http_info(self, name, n
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_head_node_proxy(self, name, **kwargs): # noqa: E501
"""connect_head_node_proxy # noqa: E501
@@ -2555,22 +3090,28 @@ def connect_head_node_proxy(self, name, **kwargs): # noqa: E501
connect HEAD requests to proxy of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_head_node_proxy(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the NodeProxyOptions (required)
- :param str path: Path is the URL path to use for the current proxy request to node.
+ :param name: name of the NodeProxyOptions (required)
+ :type name: str
+ :param path: Path is the URL path to use for the current proxy request to node.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_head_node_proxy_with_http_info(name, **kwargs) # noqa: E501
@@ -2581,24 +3122,36 @@ def connect_head_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
connect HEAD requests to proxy of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_head_node_proxy_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the NodeProxyOptions (required)
- :param str path: Path is the URL path to use for the current proxy request to node.
+ :param name: name of the NodeProxyOptions (required)
+ :type name: str
+ :param path: Path is the URL path to use for the current proxy request to node.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2612,7 +3165,10 @@ def connect_head_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2625,8 +3181,7 @@ def connect_head_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_head_node_proxy`") # noqa: E501
collection_formats = {}
@@ -2636,10 +3191,10 @@ def connect_head_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'path' in local_var_params and local_var_params['path'] is not None: # noqa: E501
+ if local_var_params.get('path') is not None: # noqa: E501
query_params.append(('path', local_var_params['path'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2652,6 +3207,11 @@ def connect_head_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/nodes/{name}/proxy', 'HEAD',
path_params,
@@ -2660,13 +3220,14 @@ def connect_head_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_head_node_proxy_with_path(self, name, path, **kwargs): # noqa: E501
"""connect_head_node_proxy_with_path # noqa: E501
@@ -2674,23 +3235,30 @@ def connect_head_node_proxy_with_path(self, name, path, **kwargs): # noqa: E501
connect HEAD requests to proxy of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_head_node_proxy_with_path(name, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the NodeProxyOptions (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the URL path to use for the current proxy request to node.
+ :param name: name of the NodeProxyOptions (required)
+ :type name: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the URL path to use for the current proxy request to node.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_head_node_proxy_with_path_with_http_info(name, path, **kwargs) # noqa: E501
@@ -2701,25 +3269,38 @@ def connect_head_node_proxy_with_path_with_http_info(self, name, path, **kwargs)
connect HEAD requests to proxy of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_head_node_proxy_with_path_with_http_info(name, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the NodeProxyOptions (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the URL path to use for the current proxy request to node.
+ :param name: name of the NodeProxyOptions (required)
+ :type name: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the URL path to use for the current proxy request to node.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2734,7 +3315,10 @@ def connect_head_node_proxy_with_path_with_http_info(self, name, path, **kwargs)
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2747,12 +3331,10 @@ def connect_head_node_proxy_with_path_with_http_info(self, name, path, **kwargs)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_head_node_proxy_with_path`") # noqa: E501
# verify the required parameter 'path' is set
- if self.api_client.client_side_validation and ('path' not in local_var_params or # noqa: E501
- local_var_params['path'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('path') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `path` when calling `connect_head_node_proxy_with_path`") # noqa: E501
collection_formats = {}
@@ -2764,10 +3346,10 @@ def connect_head_node_proxy_with_path_with_http_info(self, name, path, **kwargs)
path_params['path'] = local_var_params['path'] # noqa: E501
query_params = []
- if 'path2' in local_var_params and local_var_params['path2'] is not None: # noqa: E501
+ if local_var_params.get('path2') is not None: # noqa: E501
query_params.append(('path', local_var_params['path2'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2780,6 +3362,11 @@ def connect_head_node_proxy_with_path_with_http_info(self, name, path, **kwargs)
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/nodes/{name}/proxy/{path}', 'HEAD',
path_params,
@@ -2788,13 +3375,14 @@ def connect_head_node_proxy_with_path_with_http_info(self, name, path, **kwargs)
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_options_namespaced_pod_proxy(self, name, namespace, **kwargs): # noqa: E501
"""connect_options_namespaced_pod_proxy # noqa: E501
@@ -2802,23 +3390,30 @@ def connect_options_namespaced_pod_proxy(self, name, namespace, **kwargs): # no
connect OPTIONS requests to proxy of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_options_namespaced_pod_proxy(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: Path is the URL path to use for the current proxy request to pod.
+ :param name: name of the PodProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: Path is the URL path to use for the current proxy request to pod.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_options_namespaced_pod_proxy_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -2829,25 +3424,38 @@ def connect_options_namespaced_pod_proxy_with_http_info(self, name, namespace, *
connect OPTIONS requests to proxy of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_options_namespaced_pod_proxy_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: Path is the URL path to use for the current proxy request to pod.
+ :param name: name of the PodProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: Path is the URL path to use for the current proxy request to pod.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2862,7 +3470,10 @@ def connect_options_namespaced_pod_proxy_with_http_info(self, name, namespace, *
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2875,12 +3486,10 @@ def connect_options_namespaced_pod_proxy_with_http_info(self, name, namespace, *
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_options_namespaced_pod_proxy`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_options_namespaced_pod_proxy`") # noqa: E501
collection_formats = {}
@@ -2892,10 +3501,10 @@ def connect_options_namespaced_pod_proxy_with_http_info(self, name, namespace, *
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'path' in local_var_params and local_var_params['path'] is not None: # noqa: E501
+ if local_var_params.get('path') is not None: # noqa: E501
query_params.append(('path', local_var_params['path'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2908,6 +3517,11 @@ def connect_options_namespaced_pod_proxy_with_http_info(self, name, namespace, *
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/proxy', 'OPTIONS',
path_params,
@@ -2916,13 +3530,14 @@ def connect_options_namespaced_pod_proxy_with_http_info(self, name, namespace, *
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_options_namespaced_pod_proxy_with_path(self, name, namespace, path, **kwargs): # noqa: E501
"""connect_options_namespaced_pod_proxy_with_path # noqa: E501
@@ -2930,24 +3545,32 @@ def connect_options_namespaced_pod_proxy_with_path(self, name, namespace, path,
connect OPTIONS requests to proxy of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_options_namespaced_pod_proxy_with_path(name, namespace, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the URL path to use for the current proxy request to pod.
+ :param name: name of the PodProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the URL path to use for the current proxy request to pod.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_options_namespaced_pod_proxy_with_path_with_http_info(name, namespace, path, **kwargs) # noqa: E501
@@ -2958,26 +3581,40 @@ def connect_options_namespaced_pod_proxy_with_path_with_http_info(self, name, na
connect OPTIONS requests to proxy of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_options_namespaced_pod_proxy_with_path_with_http_info(name, namespace, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the URL path to use for the current proxy request to pod.
+ :param name: name of the PodProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the URL path to use for the current proxy request to pod.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2993,7 +3630,10 @@ def connect_options_namespaced_pod_proxy_with_path_with_http_info(self, name, na
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3006,16 +3646,13 @@ def connect_options_namespaced_pod_proxy_with_path_with_http_info(self, name, na
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_options_namespaced_pod_proxy_with_path`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_options_namespaced_pod_proxy_with_path`") # noqa: E501
# verify the required parameter 'path' is set
- if self.api_client.client_side_validation and ('path' not in local_var_params or # noqa: E501
- local_var_params['path'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('path') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `path` when calling `connect_options_namespaced_pod_proxy_with_path`") # noqa: E501
collection_formats = {}
@@ -3029,10 +3666,10 @@ def connect_options_namespaced_pod_proxy_with_path_with_http_info(self, name, na
path_params['path'] = local_var_params['path'] # noqa: E501
query_params = []
- if 'path2' in local_var_params and local_var_params['path2'] is not None: # noqa: E501
+ if local_var_params.get('path2') is not None: # noqa: E501
query_params.append(('path', local_var_params['path2'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3045,6 +3682,11 @@ def connect_options_namespaced_pod_proxy_with_path_with_http_info(self, name, na
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/proxy/{path}', 'OPTIONS',
path_params,
@@ -3053,13 +3695,14 @@ def connect_options_namespaced_pod_proxy_with_path_with_http_info(self, name, na
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_options_namespaced_service_proxy(self, name, namespace, **kwargs): # noqa: E501
"""connect_options_namespaced_service_proxy # noqa: E501
@@ -3067,23 +3710,30 @@ def connect_options_namespaced_service_proxy(self, name, namespace, **kwargs):
connect OPTIONS requests to proxy of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_options_namespaced_service_proxy(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :param name: name of the ServiceProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_options_namespaced_service_proxy_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -3094,25 +3744,38 @@ def connect_options_namespaced_service_proxy_with_http_info(self, name, namespac
connect OPTIONS requests to proxy of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_options_namespaced_service_proxy_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :param name: name of the ServiceProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3127,7 +3790,10 @@ def connect_options_namespaced_service_proxy_with_http_info(self, name, namespac
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3140,12 +3806,10 @@ def connect_options_namespaced_service_proxy_with_http_info(self, name, namespac
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_options_namespaced_service_proxy`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_options_namespaced_service_proxy`") # noqa: E501
collection_formats = {}
@@ -3157,10 +3821,10 @@ def connect_options_namespaced_service_proxy_with_http_info(self, name, namespac
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'path' in local_var_params and local_var_params['path'] is not None: # noqa: E501
+ if local_var_params.get('path') is not None: # noqa: E501
query_params.append(('path', local_var_params['path'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3173,6 +3837,11 @@ def connect_options_namespaced_service_proxy_with_http_info(self, name, namespac
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/services/{name}/proxy', 'OPTIONS',
path_params,
@@ -3181,13 +3850,14 @@ def connect_options_namespaced_service_proxy_with_http_info(self, name, namespac
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_options_namespaced_service_proxy_with_path(self, name, namespace, path, **kwargs): # noqa: E501
"""connect_options_namespaced_service_proxy_with_path # noqa: E501
@@ -3195,24 +3865,32 @@ def connect_options_namespaced_service_proxy_with_path(self, name, namespace, pa
connect OPTIONS requests to proxy of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_options_namespaced_service_proxy_with_path(name, namespace, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :param name: name of the ServiceProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_options_namespaced_service_proxy_with_path_with_http_info(name, namespace, path, **kwargs) # noqa: E501
@@ -3223,26 +3901,40 @@ def connect_options_namespaced_service_proxy_with_path_with_http_info(self, name
connect OPTIONS requests to proxy of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_options_namespaced_service_proxy_with_path_with_http_info(name, namespace, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :param name: name of the ServiceProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3258,7 +3950,10 @@ def connect_options_namespaced_service_proxy_with_path_with_http_info(self, name
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3271,16 +3966,13 @@ def connect_options_namespaced_service_proxy_with_path_with_http_info(self, name
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_options_namespaced_service_proxy_with_path`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_options_namespaced_service_proxy_with_path`") # noqa: E501
# verify the required parameter 'path' is set
- if self.api_client.client_side_validation and ('path' not in local_var_params or # noqa: E501
- local_var_params['path'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('path') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `path` when calling `connect_options_namespaced_service_proxy_with_path`") # noqa: E501
collection_formats = {}
@@ -3294,10 +3986,10 @@ def connect_options_namespaced_service_proxy_with_path_with_http_info(self, name
path_params['path'] = local_var_params['path'] # noqa: E501
query_params = []
- if 'path2' in local_var_params and local_var_params['path2'] is not None: # noqa: E501
+ if local_var_params.get('path2') is not None: # noqa: E501
query_params.append(('path', local_var_params['path2'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3310,6 +4002,11 @@ def connect_options_namespaced_service_proxy_with_path_with_http_info(self, name
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/services/{name}/proxy/{path}', 'OPTIONS',
path_params,
@@ -3318,13 +4015,14 @@ def connect_options_namespaced_service_proxy_with_path_with_http_info(self, name
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_options_node_proxy(self, name, **kwargs): # noqa: E501
"""connect_options_node_proxy # noqa: E501
@@ -3332,22 +4030,28 @@ def connect_options_node_proxy(self, name, **kwargs): # noqa: E501
connect OPTIONS requests to proxy of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_options_node_proxy(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the NodeProxyOptions (required)
- :param str path: Path is the URL path to use for the current proxy request to node.
+ :param name: name of the NodeProxyOptions (required)
+ :type name: str
+ :param path: Path is the URL path to use for the current proxy request to node.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_options_node_proxy_with_http_info(name, **kwargs) # noqa: E501
@@ -3358,24 +4062,36 @@ def connect_options_node_proxy_with_http_info(self, name, **kwargs): # noqa: E5
connect OPTIONS requests to proxy of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_options_node_proxy_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the NodeProxyOptions (required)
- :param str path: Path is the URL path to use for the current proxy request to node.
+ :param name: name of the NodeProxyOptions (required)
+ :type name: str
+ :param path: Path is the URL path to use for the current proxy request to node.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3389,7 +4105,10 @@ def connect_options_node_proxy_with_http_info(self, name, **kwargs): # noqa: E5
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3402,8 +4121,7 @@ def connect_options_node_proxy_with_http_info(self, name, **kwargs): # noqa: E5
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_options_node_proxy`") # noqa: E501
collection_formats = {}
@@ -3413,10 +4131,10 @@ def connect_options_node_proxy_with_http_info(self, name, **kwargs): # noqa: E5
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'path' in local_var_params and local_var_params['path'] is not None: # noqa: E501
+ if local_var_params.get('path') is not None: # noqa: E501
query_params.append(('path', local_var_params['path'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3429,6 +4147,11 @@ def connect_options_node_proxy_with_http_info(self, name, **kwargs): # noqa: E5
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/nodes/{name}/proxy', 'OPTIONS',
path_params,
@@ -3437,13 +4160,14 @@ def connect_options_node_proxy_with_http_info(self, name, **kwargs): # noqa: E5
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_options_node_proxy_with_path(self, name, path, **kwargs): # noqa: E501
"""connect_options_node_proxy_with_path # noqa: E501
@@ -3451,23 +4175,30 @@ def connect_options_node_proxy_with_path(self, name, path, **kwargs): # noqa: E
connect OPTIONS requests to proxy of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_options_node_proxy_with_path(name, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the NodeProxyOptions (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the URL path to use for the current proxy request to node.
+ :param name: name of the NodeProxyOptions (required)
+ :type name: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the URL path to use for the current proxy request to node.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_options_node_proxy_with_path_with_http_info(name, path, **kwargs) # noqa: E501
@@ -3478,25 +4209,38 @@ def connect_options_node_proxy_with_path_with_http_info(self, name, path, **kwar
connect OPTIONS requests to proxy of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_options_node_proxy_with_path_with_http_info(name, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the NodeProxyOptions (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the URL path to use for the current proxy request to node.
+ :param name: name of the NodeProxyOptions (required)
+ :type name: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the URL path to use for the current proxy request to node.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3511,7 +4255,10 @@ def connect_options_node_proxy_with_path_with_http_info(self, name, path, **kwar
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3524,12 +4271,10 @@ def connect_options_node_proxy_with_path_with_http_info(self, name, path, **kwar
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_options_node_proxy_with_path`") # noqa: E501
# verify the required parameter 'path' is set
- if self.api_client.client_side_validation and ('path' not in local_var_params or # noqa: E501
- local_var_params['path'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('path') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `path` when calling `connect_options_node_proxy_with_path`") # noqa: E501
collection_formats = {}
@@ -3541,10 +4286,10 @@ def connect_options_node_proxy_with_path_with_http_info(self, name, path, **kwar
path_params['path'] = local_var_params['path'] # noqa: E501
query_params = []
- if 'path2' in local_var_params and local_var_params['path2'] is not None: # noqa: E501
+ if local_var_params.get('path2') is not None: # noqa: E501
query_params.append(('path', local_var_params['path2'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3557,6 +4302,11 @@ def connect_options_node_proxy_with_path_with_http_info(self, name, path, **kwar
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/nodes/{name}/proxy/{path}', 'OPTIONS',
path_params,
@@ -3565,13 +4315,14 @@ def connect_options_node_proxy_with_path_with_http_info(self, name, path, **kwar
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_patch_namespaced_pod_proxy(self, name, namespace, **kwargs): # noqa: E501
"""connect_patch_namespaced_pod_proxy # noqa: E501
@@ -3579,23 +4330,30 @@ def connect_patch_namespaced_pod_proxy(self, name, namespace, **kwargs): # noqa
connect PATCH requests to proxy of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_patch_namespaced_pod_proxy(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: Path is the URL path to use for the current proxy request to pod.
+ :param name: name of the PodProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: Path is the URL path to use for the current proxy request to pod.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_patch_namespaced_pod_proxy_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -3606,25 +4364,38 @@ def connect_patch_namespaced_pod_proxy_with_http_info(self, name, namespace, **k
connect PATCH requests to proxy of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_patch_namespaced_pod_proxy_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: Path is the URL path to use for the current proxy request to pod.
+ :param name: name of the PodProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: Path is the URL path to use for the current proxy request to pod.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3639,7 +4410,10 @@ def connect_patch_namespaced_pod_proxy_with_http_info(self, name, namespace, **k
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3652,12 +4426,10 @@ def connect_patch_namespaced_pod_proxy_with_http_info(self, name, namespace, **k
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_patch_namespaced_pod_proxy`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_patch_namespaced_pod_proxy`") # noqa: E501
collection_formats = {}
@@ -3669,10 +4441,10 @@ def connect_patch_namespaced_pod_proxy_with_http_info(self, name, namespace, **k
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'path' in local_var_params and local_var_params['path'] is not None: # noqa: E501
+ if local_var_params.get('path') is not None: # noqa: E501
query_params.append(('path', local_var_params['path'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3685,6 +4457,11 @@ def connect_patch_namespaced_pod_proxy_with_http_info(self, name, namespace, **k
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/proxy', 'PATCH',
path_params,
@@ -3693,13 +4470,14 @@ def connect_patch_namespaced_pod_proxy_with_http_info(self, name, namespace, **k
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_patch_namespaced_pod_proxy_with_path(self, name, namespace, path, **kwargs): # noqa: E501
"""connect_patch_namespaced_pod_proxy_with_path # noqa: E501
@@ -3707,24 +4485,32 @@ def connect_patch_namespaced_pod_proxy_with_path(self, name, namespace, path, **
connect PATCH requests to proxy of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_patch_namespaced_pod_proxy_with_path(name, namespace, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the URL path to use for the current proxy request to pod.
+ :param name: name of the PodProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the URL path to use for the current proxy request to pod.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_patch_namespaced_pod_proxy_with_path_with_http_info(name, namespace, path, **kwargs) # noqa: E501
@@ -3735,26 +4521,40 @@ def connect_patch_namespaced_pod_proxy_with_path_with_http_info(self, name, name
connect PATCH requests to proxy of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_patch_namespaced_pod_proxy_with_path_with_http_info(name, namespace, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the URL path to use for the current proxy request to pod.
+ :param name: name of the PodProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the URL path to use for the current proxy request to pod.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3770,7 +4570,10 @@ def connect_patch_namespaced_pod_proxy_with_path_with_http_info(self, name, name
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3783,16 +4586,13 @@ def connect_patch_namespaced_pod_proxy_with_path_with_http_info(self, name, name
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_patch_namespaced_pod_proxy_with_path`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_patch_namespaced_pod_proxy_with_path`") # noqa: E501
# verify the required parameter 'path' is set
- if self.api_client.client_side_validation and ('path' not in local_var_params or # noqa: E501
- local_var_params['path'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('path') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `path` when calling `connect_patch_namespaced_pod_proxy_with_path`") # noqa: E501
collection_formats = {}
@@ -3806,10 +4606,10 @@ def connect_patch_namespaced_pod_proxy_with_path_with_http_info(self, name, name
path_params['path'] = local_var_params['path'] # noqa: E501
query_params = []
- if 'path2' in local_var_params and local_var_params['path2'] is not None: # noqa: E501
+ if local_var_params.get('path2') is not None: # noqa: E501
query_params.append(('path', local_var_params['path2'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3822,6 +4622,11 @@ def connect_patch_namespaced_pod_proxy_with_path_with_http_info(self, name, name
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/proxy/{path}', 'PATCH',
path_params,
@@ -3830,13 +4635,14 @@ def connect_patch_namespaced_pod_proxy_with_path_with_http_info(self, name, name
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_patch_namespaced_service_proxy(self, name, namespace, **kwargs): # noqa: E501
"""connect_patch_namespaced_service_proxy # noqa: E501
@@ -3844,23 +4650,30 @@ def connect_patch_namespaced_service_proxy(self, name, namespace, **kwargs): #
connect PATCH requests to proxy of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_patch_namespaced_service_proxy(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :param name: name of the ServiceProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_patch_namespaced_service_proxy_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -3871,25 +4684,38 @@ def connect_patch_namespaced_service_proxy_with_http_info(self, name, namespace,
connect PATCH requests to proxy of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_patch_namespaced_service_proxy_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :param name: name of the ServiceProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3904,7 +4730,10 @@ def connect_patch_namespaced_service_proxy_with_http_info(self, name, namespace,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3917,12 +4746,10 @@ def connect_patch_namespaced_service_proxy_with_http_info(self, name, namespace,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_patch_namespaced_service_proxy`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_patch_namespaced_service_proxy`") # noqa: E501
collection_formats = {}
@@ -3934,10 +4761,10 @@ def connect_patch_namespaced_service_proxy_with_http_info(self, name, namespace,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'path' in local_var_params and local_var_params['path'] is not None: # noqa: E501
+ if local_var_params.get('path') is not None: # noqa: E501
query_params.append(('path', local_var_params['path'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3950,6 +4777,11 @@ def connect_patch_namespaced_service_proxy_with_http_info(self, name, namespace,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/services/{name}/proxy', 'PATCH',
path_params,
@@ -3958,13 +4790,14 @@ def connect_patch_namespaced_service_proxy_with_http_info(self, name, namespace,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_patch_namespaced_service_proxy_with_path(self, name, namespace, path, **kwargs): # noqa: E501
"""connect_patch_namespaced_service_proxy_with_path # noqa: E501
@@ -3972,24 +4805,32 @@ def connect_patch_namespaced_service_proxy_with_path(self, name, namespace, path
connect PATCH requests to proxy of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_patch_namespaced_service_proxy_with_path(name, namespace, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :param name: name of the ServiceProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_patch_namespaced_service_proxy_with_path_with_http_info(name, namespace, path, **kwargs) # noqa: E501
@@ -4000,26 +4841,40 @@ def connect_patch_namespaced_service_proxy_with_path_with_http_info(self, name,
connect PATCH requests to proxy of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_patch_namespaced_service_proxy_with_path_with_http_info(name, namespace, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :param name: name of the ServiceProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -4035,7 +4890,10 @@ def connect_patch_namespaced_service_proxy_with_path_with_http_info(self, name,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -4048,16 +4906,13 @@ def connect_patch_namespaced_service_proxy_with_path_with_http_info(self, name,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_patch_namespaced_service_proxy_with_path`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_patch_namespaced_service_proxy_with_path`") # noqa: E501
# verify the required parameter 'path' is set
- if self.api_client.client_side_validation and ('path' not in local_var_params or # noqa: E501
- local_var_params['path'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('path') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `path` when calling `connect_patch_namespaced_service_proxy_with_path`") # noqa: E501
collection_formats = {}
@@ -4071,10 +4926,10 @@ def connect_patch_namespaced_service_proxy_with_path_with_http_info(self, name,
path_params['path'] = local_var_params['path'] # noqa: E501
query_params = []
- if 'path2' in local_var_params and local_var_params['path2'] is not None: # noqa: E501
+ if local_var_params.get('path2') is not None: # noqa: E501
query_params.append(('path', local_var_params['path2'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -4087,6 +4942,11 @@ def connect_patch_namespaced_service_proxy_with_path_with_http_info(self, name,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/services/{name}/proxy/{path}', 'PATCH',
path_params,
@@ -4095,13 +4955,14 @@ def connect_patch_namespaced_service_proxy_with_path_with_http_info(self, name,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_patch_node_proxy(self, name, **kwargs): # noqa: E501
"""connect_patch_node_proxy # noqa: E501
@@ -4109,22 +4970,28 @@ def connect_patch_node_proxy(self, name, **kwargs): # noqa: E501
connect PATCH requests to proxy of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_patch_node_proxy(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the NodeProxyOptions (required)
- :param str path: Path is the URL path to use for the current proxy request to node.
+ :param name: name of the NodeProxyOptions (required)
+ :type name: str
+ :param path: Path is the URL path to use for the current proxy request to node.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_patch_node_proxy_with_http_info(name, **kwargs) # noqa: E501
@@ -4135,24 +5002,36 @@ def connect_patch_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
connect PATCH requests to proxy of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_patch_node_proxy_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the NodeProxyOptions (required)
- :param str path: Path is the URL path to use for the current proxy request to node.
+ :param name: name of the NodeProxyOptions (required)
+ :type name: str
+ :param path: Path is the URL path to use for the current proxy request to node.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -4166,7 +5045,10 @@ def connect_patch_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -4179,8 +5061,7 @@ def connect_patch_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_patch_node_proxy`") # noqa: E501
collection_formats = {}
@@ -4190,10 +5071,10 @@ def connect_patch_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'path' in local_var_params and local_var_params['path'] is not None: # noqa: E501
+ if local_var_params.get('path') is not None: # noqa: E501
query_params.append(('path', local_var_params['path'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -4206,6 +5087,11 @@ def connect_patch_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/nodes/{name}/proxy', 'PATCH',
path_params,
@@ -4214,13 +5100,14 @@ def connect_patch_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_patch_node_proxy_with_path(self, name, path, **kwargs): # noqa: E501
"""connect_patch_node_proxy_with_path # noqa: E501
@@ -4228,23 +5115,30 @@ def connect_patch_node_proxy_with_path(self, name, path, **kwargs): # noqa: E50
connect PATCH requests to proxy of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_patch_node_proxy_with_path(name, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the NodeProxyOptions (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the URL path to use for the current proxy request to node.
+ :param name: name of the NodeProxyOptions (required)
+ :type name: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the URL path to use for the current proxy request to node.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_patch_node_proxy_with_path_with_http_info(name, path, **kwargs) # noqa: E501
@@ -4255,25 +5149,38 @@ def connect_patch_node_proxy_with_path_with_http_info(self, name, path, **kwargs
connect PATCH requests to proxy of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_patch_node_proxy_with_path_with_http_info(name, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the NodeProxyOptions (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the URL path to use for the current proxy request to node.
+ :param name: name of the NodeProxyOptions (required)
+ :type name: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the URL path to use for the current proxy request to node.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -4288,7 +5195,10 @@ def connect_patch_node_proxy_with_path_with_http_info(self, name, path, **kwargs
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -4301,12 +5211,10 @@ def connect_patch_node_proxy_with_path_with_http_info(self, name, path, **kwargs
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_patch_node_proxy_with_path`") # noqa: E501
# verify the required parameter 'path' is set
- if self.api_client.client_side_validation and ('path' not in local_var_params or # noqa: E501
- local_var_params['path'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('path') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `path` when calling `connect_patch_node_proxy_with_path`") # noqa: E501
collection_formats = {}
@@ -4318,10 +5226,10 @@ def connect_patch_node_proxy_with_path_with_http_info(self, name, path, **kwargs
path_params['path'] = local_var_params['path'] # noqa: E501
query_params = []
- if 'path2' in local_var_params and local_var_params['path2'] is not None: # noqa: E501
+ if local_var_params.get('path2') is not None: # noqa: E501
query_params.append(('path', local_var_params['path2'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -4334,6 +5242,11 @@ def connect_patch_node_proxy_with_path_with_http_info(self, name, path, **kwargs
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/nodes/{name}/proxy/{path}', 'PATCH',
path_params,
@@ -4342,13 +5255,14 @@ def connect_patch_node_proxy_with_path_with_http_info(self, name, path, **kwargs
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_post_namespaced_pod_attach(self, name, namespace, **kwargs): # noqa: E501
"""connect_post_namespaced_pod_attach # noqa: E501
@@ -4356,27 +5270,38 @@ def connect_post_namespaced_pod_attach(self, name, namespace, **kwargs): # noqa
connect POST requests to attach of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_post_namespaced_pod_attach(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodAttachOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str container: The container in which to execute the command. Defaults to only container if there is only one container in the pod.
- :param bool stderr: Stderr if true indicates that stderr is to be redirected for the attach call. Defaults to true.
- :param bool stdin: Stdin if true, redirects the standard input stream of the pod for this call. Defaults to false.
- :param bool stdout: Stdout if true indicates that stdout is to be redirected for the attach call. Defaults to true.
- :param bool tty: TTY if true indicates that a tty will be allocated for the attach call. This is passed through the container runtime so the tty is allocated on the worker node by the container runtime. Defaults to false.
+ :param name: name of the PodAttachOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param container: The container in which to execute the command. Defaults to only container if there is only one container in the pod.
+ :type container: str
+ :param stderr: Stderr if true indicates that stderr is to be redirected for the attach call. Defaults to true.
+ :type stderr: bool
+ :param stdin: Stdin if true, redirects the standard input stream of the pod for this call. Defaults to false.
+ :type stdin: bool
+ :param stdout: Stdout if true indicates that stdout is to be redirected for the attach call. Defaults to true.
+ :type stdout: bool
+ :param tty: TTY if true indicates that a tty will be allocated for the attach call. This is passed through the container runtime so the tty is allocated on the worker node by the container runtime. Defaults to false.
+ :type tty: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_post_namespaced_pod_attach_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -4387,29 +5312,46 @@ def connect_post_namespaced_pod_attach_with_http_info(self, name, namespace, **k
connect POST requests to attach of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_post_namespaced_pod_attach_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodAttachOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str container: The container in which to execute the command. Defaults to only container if there is only one container in the pod.
- :param bool stderr: Stderr if true indicates that stderr is to be redirected for the attach call. Defaults to true.
- :param bool stdin: Stdin if true, redirects the standard input stream of the pod for this call. Defaults to false.
- :param bool stdout: Stdout if true indicates that stdout is to be redirected for the attach call. Defaults to true.
- :param bool tty: TTY if true indicates that a tty will be allocated for the attach call. This is passed through the container runtime so the tty is allocated on the worker node by the container runtime. Defaults to false.
+ :param name: name of the PodAttachOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param container: The container in which to execute the command. Defaults to only container if there is only one container in the pod.
+ :type container: str
+ :param stderr: Stderr if true indicates that stderr is to be redirected for the attach call. Defaults to true.
+ :type stderr: bool
+ :param stdin: Stdin if true, redirects the standard input stream of the pod for this call. Defaults to false.
+ :type stdin: bool
+ :param stdout: Stdout if true indicates that stdout is to be redirected for the attach call. Defaults to true.
+ :type stdout: bool
+ :param tty: TTY if true indicates that a tty will be allocated for the attach call. This is passed through the container runtime so the tty is allocated on the worker node by the container runtime. Defaults to false.
+ :type tty: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -4428,7 +5370,10 @@ def connect_post_namespaced_pod_attach_with_http_info(self, name, namespace, **k
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -4441,12 +5386,10 @@ def connect_post_namespaced_pod_attach_with_http_info(self, name, namespace, **k
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_post_namespaced_pod_attach`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_post_namespaced_pod_attach`") # noqa: E501
collection_formats = {}
@@ -4458,18 +5401,18 @@ def connect_post_namespaced_pod_attach_with_http_info(self, name, namespace, **k
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'container' in local_var_params and local_var_params['container'] is not None: # noqa: E501
+ if local_var_params.get('container') is not None: # noqa: E501
query_params.append(('container', local_var_params['container'])) # noqa: E501
- if 'stderr' in local_var_params and local_var_params['stderr'] is not None: # noqa: E501
+ if local_var_params.get('stderr') is not None: # noqa: E501
query_params.append(('stderr', local_var_params['stderr'])) # noqa: E501
- if 'stdin' in local_var_params and local_var_params['stdin'] is not None: # noqa: E501
+ if local_var_params.get('stdin') is not None: # noqa: E501
query_params.append(('stdin', local_var_params['stdin'])) # noqa: E501
- if 'stdout' in local_var_params and local_var_params['stdout'] is not None: # noqa: E501
+ if local_var_params.get('stdout') is not None: # noqa: E501
query_params.append(('stdout', local_var_params['stdout'])) # noqa: E501
- if 'tty' in local_var_params and local_var_params['tty'] is not None: # noqa: E501
+ if local_var_params.get('tty') is not None: # noqa: E501
query_params.append(('tty', local_var_params['tty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -4482,6 +5425,11 @@ def connect_post_namespaced_pod_attach_with_http_info(self, name, namespace, **k
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/attach', 'POST',
path_params,
@@ -4490,13 +5438,14 @@ def connect_post_namespaced_pod_attach_with_http_info(self, name, namespace, **k
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_post_namespaced_pod_exec(self, name, namespace, **kwargs): # noqa: E501
"""connect_post_namespaced_pod_exec # noqa: E501
@@ -4504,28 +5453,40 @@ def connect_post_namespaced_pod_exec(self, name, namespace, **kwargs): # noqa:
connect POST requests to exec of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_post_namespaced_pod_exec(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodExecOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str command: Command is the remote command to execute. argv array. Not executed within a shell.
- :param str container: Container in which to execute the command. Defaults to only container if there is only one container in the pod.
- :param bool stderr: Redirect the standard error stream of the pod for this call.
- :param bool stdin: Redirect the standard input stream of the pod for this call. Defaults to false.
- :param bool stdout: Redirect the standard output stream of the pod for this call.
- :param bool tty: TTY if true indicates that a tty will be allocated for the exec call. Defaults to false.
+ :param name: name of the PodExecOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param command: Command is the remote command to execute. argv array. Not executed within a shell.
+ :type command: str
+ :param container: Container in which to execute the command. Defaults to only container if there is only one container in the pod.
+ :type container: str
+ :param stderr: Redirect the standard error stream of the pod for this call.
+ :type stderr: bool
+ :param stdin: Redirect the standard input stream of the pod for this call. Defaults to false.
+ :type stdin: bool
+ :param stdout: Redirect the standard output stream of the pod for this call.
+ :type stdout: bool
+ :param tty: TTY if true indicates that a tty will be allocated for the exec call. Defaults to false.
+ :type tty: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_post_namespaced_pod_exec_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -4536,30 +5497,48 @@ def connect_post_namespaced_pod_exec_with_http_info(self, name, namespace, **kwa
connect POST requests to exec of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_post_namespaced_pod_exec_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodExecOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str command: Command is the remote command to execute. argv array. Not executed within a shell.
- :param str container: Container in which to execute the command. Defaults to only container if there is only one container in the pod.
- :param bool stderr: Redirect the standard error stream of the pod for this call.
- :param bool stdin: Redirect the standard input stream of the pod for this call. Defaults to false.
- :param bool stdout: Redirect the standard output stream of the pod for this call.
- :param bool tty: TTY if true indicates that a tty will be allocated for the exec call. Defaults to false.
+ :param name: name of the PodExecOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param command: Command is the remote command to execute. argv array. Not executed within a shell.
+ :type command: str
+ :param container: Container in which to execute the command. Defaults to only container if there is only one container in the pod.
+ :type container: str
+ :param stderr: Redirect the standard error stream of the pod for this call.
+ :type stderr: bool
+ :param stdin: Redirect the standard input stream of the pod for this call. Defaults to false.
+ :type stdin: bool
+ :param stdout: Redirect the standard output stream of the pod for this call.
+ :type stdout: bool
+ :param tty: TTY if true indicates that a tty will be allocated for the exec call. Defaults to false.
+ :type tty: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -4579,7 +5558,10 @@ def connect_post_namespaced_pod_exec_with_http_info(self, name, namespace, **kwa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -4592,12 +5574,10 @@ def connect_post_namespaced_pod_exec_with_http_info(self, name, namespace, **kwa
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_post_namespaced_pod_exec`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_post_namespaced_pod_exec`") # noqa: E501
collection_formats = {}
@@ -4609,20 +5589,20 @@ def connect_post_namespaced_pod_exec_with_http_info(self, name, namespace, **kwa
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'command' in local_var_params and local_var_params['command'] is not None: # noqa: E501
+ if local_var_params.get('command') is not None: # noqa: E501
query_params.append(('command', local_var_params['command'])) # noqa: E501
- if 'container' in local_var_params and local_var_params['container'] is not None: # noqa: E501
+ if local_var_params.get('container') is not None: # noqa: E501
query_params.append(('container', local_var_params['container'])) # noqa: E501
- if 'stderr' in local_var_params and local_var_params['stderr'] is not None: # noqa: E501
+ if local_var_params.get('stderr') is not None: # noqa: E501
query_params.append(('stderr', local_var_params['stderr'])) # noqa: E501
- if 'stdin' in local_var_params and local_var_params['stdin'] is not None: # noqa: E501
+ if local_var_params.get('stdin') is not None: # noqa: E501
query_params.append(('stdin', local_var_params['stdin'])) # noqa: E501
- if 'stdout' in local_var_params and local_var_params['stdout'] is not None: # noqa: E501
+ if local_var_params.get('stdout') is not None: # noqa: E501
query_params.append(('stdout', local_var_params['stdout'])) # noqa: E501
- if 'tty' in local_var_params and local_var_params['tty'] is not None: # noqa: E501
+ if local_var_params.get('tty') is not None: # noqa: E501
query_params.append(('tty', local_var_params['tty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -4635,6 +5615,11 @@ def connect_post_namespaced_pod_exec_with_http_info(self, name, namespace, **kwa
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/exec', 'POST',
path_params,
@@ -4643,13 +5628,14 @@ def connect_post_namespaced_pod_exec_with_http_info(self, name, namespace, **kwa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_post_namespaced_pod_portforward(self, name, namespace, **kwargs): # noqa: E501
"""connect_post_namespaced_pod_portforward # noqa: E501
@@ -4657,23 +5643,30 @@ def connect_post_namespaced_pod_portforward(self, name, namespace, **kwargs): #
connect POST requests to portforward of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_post_namespaced_pod_portforward(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodPortForwardOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param int ports: List of ports to forward Required when using WebSockets
+ :param name: name of the PodPortForwardOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param ports: List of ports to forward Required when using WebSockets
+ :type ports: int
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_post_namespaced_pod_portforward_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -4684,25 +5677,38 @@ def connect_post_namespaced_pod_portforward_with_http_info(self, name, namespace
connect POST requests to portforward of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_post_namespaced_pod_portforward_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodPortForwardOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param int ports: List of ports to forward Required when using WebSockets
+ :param name: name of the PodPortForwardOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param ports: List of ports to forward Required when using WebSockets
+ :type ports: int
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -4717,7 +5723,10 @@ def connect_post_namespaced_pod_portforward_with_http_info(self, name, namespace
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -4730,12 +5739,10 @@ def connect_post_namespaced_pod_portforward_with_http_info(self, name, namespace
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_post_namespaced_pod_portforward`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_post_namespaced_pod_portforward`") # noqa: E501
collection_formats = {}
@@ -4747,10 +5754,10 @@ def connect_post_namespaced_pod_portforward_with_http_info(self, name, namespace
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'ports' in local_var_params and local_var_params['ports'] is not None: # noqa: E501
+ if local_var_params.get('ports') is not None: # noqa: E501
query_params.append(('ports', local_var_params['ports'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -4763,6 +5770,11 @@ def connect_post_namespaced_pod_portforward_with_http_info(self, name, namespace
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/portforward', 'POST',
path_params,
@@ -4771,13 +5783,14 @@ def connect_post_namespaced_pod_portforward_with_http_info(self, name, namespace
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_post_namespaced_pod_proxy(self, name, namespace, **kwargs): # noqa: E501
"""connect_post_namespaced_pod_proxy # noqa: E501
@@ -4785,23 +5798,30 @@ def connect_post_namespaced_pod_proxy(self, name, namespace, **kwargs): # noqa:
connect POST requests to proxy of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_post_namespaced_pod_proxy(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: Path is the URL path to use for the current proxy request to pod.
+ :param name: name of the PodProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: Path is the URL path to use for the current proxy request to pod.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_post_namespaced_pod_proxy_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -4812,25 +5832,38 @@ def connect_post_namespaced_pod_proxy_with_http_info(self, name, namespace, **kw
connect POST requests to proxy of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_post_namespaced_pod_proxy_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: Path is the URL path to use for the current proxy request to pod.
+ :param name: name of the PodProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: Path is the URL path to use for the current proxy request to pod.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -4845,7 +5878,10 @@ def connect_post_namespaced_pod_proxy_with_http_info(self, name, namespace, **kw
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -4858,12 +5894,10 @@ def connect_post_namespaced_pod_proxy_with_http_info(self, name, namespace, **kw
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_post_namespaced_pod_proxy`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_post_namespaced_pod_proxy`") # noqa: E501
collection_formats = {}
@@ -4875,10 +5909,10 @@ def connect_post_namespaced_pod_proxy_with_http_info(self, name, namespace, **kw
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'path' in local_var_params and local_var_params['path'] is not None: # noqa: E501
+ if local_var_params.get('path') is not None: # noqa: E501
query_params.append(('path', local_var_params['path'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -4891,6 +5925,11 @@ def connect_post_namespaced_pod_proxy_with_http_info(self, name, namespace, **kw
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/proxy', 'POST',
path_params,
@@ -4899,13 +5938,14 @@ def connect_post_namespaced_pod_proxy_with_http_info(self, name, namespace, **kw
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_post_namespaced_pod_proxy_with_path(self, name, namespace, path, **kwargs): # noqa: E501
"""connect_post_namespaced_pod_proxy_with_path # noqa: E501
@@ -4913,24 +5953,32 @@ def connect_post_namespaced_pod_proxy_with_path(self, name, namespace, path, **k
connect POST requests to proxy of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_post_namespaced_pod_proxy_with_path(name, namespace, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the URL path to use for the current proxy request to pod.
+ :param name: name of the PodProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the URL path to use for the current proxy request to pod.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_post_namespaced_pod_proxy_with_path_with_http_info(name, namespace, path, **kwargs) # noqa: E501
@@ -4941,26 +5989,40 @@ def connect_post_namespaced_pod_proxy_with_path_with_http_info(self, name, names
connect POST requests to proxy of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_post_namespaced_pod_proxy_with_path_with_http_info(name, namespace, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the URL path to use for the current proxy request to pod.
+ :param name: name of the PodProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the URL path to use for the current proxy request to pod.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -4976,7 +6038,10 @@ def connect_post_namespaced_pod_proxy_with_path_with_http_info(self, name, names
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -4989,16 +6054,13 @@ def connect_post_namespaced_pod_proxy_with_path_with_http_info(self, name, names
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_post_namespaced_pod_proxy_with_path`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_post_namespaced_pod_proxy_with_path`") # noqa: E501
# verify the required parameter 'path' is set
- if self.api_client.client_side_validation and ('path' not in local_var_params or # noqa: E501
- local_var_params['path'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('path') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `path` when calling `connect_post_namespaced_pod_proxy_with_path`") # noqa: E501
collection_formats = {}
@@ -5012,10 +6074,10 @@ def connect_post_namespaced_pod_proxy_with_path_with_http_info(self, name, names
path_params['path'] = local_var_params['path'] # noqa: E501
query_params = []
- if 'path2' in local_var_params and local_var_params['path2'] is not None: # noqa: E501
+ if local_var_params.get('path2') is not None: # noqa: E501
query_params.append(('path', local_var_params['path2'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -5028,6 +6090,11 @@ def connect_post_namespaced_pod_proxy_with_path_with_http_info(self, name, names
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/proxy/{path}', 'POST',
path_params,
@@ -5036,13 +6103,14 @@ def connect_post_namespaced_pod_proxy_with_path_with_http_info(self, name, names
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_post_namespaced_service_proxy(self, name, namespace, **kwargs): # noqa: E501
"""connect_post_namespaced_service_proxy # noqa: E501
@@ -5050,23 +6118,30 @@ def connect_post_namespaced_service_proxy(self, name, namespace, **kwargs): # n
connect POST requests to proxy of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_post_namespaced_service_proxy(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :param name: name of the ServiceProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_post_namespaced_service_proxy_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -5077,25 +6152,38 @@ def connect_post_namespaced_service_proxy_with_http_info(self, name, namespace,
connect POST requests to proxy of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_post_namespaced_service_proxy_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :param name: name of the ServiceProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -5110,7 +6198,10 @@ def connect_post_namespaced_service_proxy_with_http_info(self, name, namespace,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -5123,12 +6214,10 @@ def connect_post_namespaced_service_proxy_with_http_info(self, name, namespace,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_post_namespaced_service_proxy`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_post_namespaced_service_proxy`") # noqa: E501
collection_formats = {}
@@ -5140,10 +6229,10 @@ def connect_post_namespaced_service_proxy_with_http_info(self, name, namespace,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'path' in local_var_params and local_var_params['path'] is not None: # noqa: E501
+ if local_var_params.get('path') is not None: # noqa: E501
query_params.append(('path', local_var_params['path'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -5156,6 +6245,11 @@ def connect_post_namespaced_service_proxy_with_http_info(self, name, namespace,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/services/{name}/proxy', 'POST',
path_params,
@@ -5164,13 +6258,14 @@ def connect_post_namespaced_service_proxy_with_http_info(self, name, namespace,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_post_namespaced_service_proxy_with_path(self, name, namespace, path, **kwargs): # noqa: E501
"""connect_post_namespaced_service_proxy_with_path # noqa: E501
@@ -5178,24 +6273,32 @@ def connect_post_namespaced_service_proxy_with_path(self, name, namespace, path,
connect POST requests to proxy of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_post_namespaced_service_proxy_with_path(name, namespace, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :param name: name of the ServiceProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_post_namespaced_service_proxy_with_path_with_http_info(name, namespace, path, **kwargs) # noqa: E501
@@ -5206,26 +6309,40 @@ def connect_post_namespaced_service_proxy_with_path_with_http_info(self, name, n
connect POST requests to proxy of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_post_namespaced_service_proxy_with_path_with_http_info(name, namespace, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :param name: name of the ServiceProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -5241,7 +6358,10 @@ def connect_post_namespaced_service_proxy_with_path_with_http_info(self, name, n
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -5254,16 +6374,13 @@ def connect_post_namespaced_service_proxy_with_path_with_http_info(self, name, n
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_post_namespaced_service_proxy_with_path`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_post_namespaced_service_proxy_with_path`") # noqa: E501
# verify the required parameter 'path' is set
- if self.api_client.client_side_validation and ('path' not in local_var_params or # noqa: E501
- local_var_params['path'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('path') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `path` when calling `connect_post_namespaced_service_proxy_with_path`") # noqa: E501
collection_formats = {}
@@ -5277,10 +6394,10 @@ def connect_post_namespaced_service_proxy_with_path_with_http_info(self, name, n
path_params['path'] = local_var_params['path'] # noqa: E501
query_params = []
- if 'path2' in local_var_params and local_var_params['path2'] is not None: # noqa: E501
+ if local_var_params.get('path2') is not None: # noqa: E501
query_params.append(('path', local_var_params['path2'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -5293,6 +6410,11 @@ def connect_post_namespaced_service_proxy_with_path_with_http_info(self, name, n
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/services/{name}/proxy/{path}', 'POST',
path_params,
@@ -5301,13 +6423,14 @@ def connect_post_namespaced_service_proxy_with_path_with_http_info(self, name, n
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_post_node_proxy(self, name, **kwargs): # noqa: E501
"""connect_post_node_proxy # noqa: E501
@@ -5315,22 +6438,28 @@ def connect_post_node_proxy(self, name, **kwargs): # noqa: E501
connect POST requests to proxy of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_post_node_proxy(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the NodeProxyOptions (required)
- :param str path: Path is the URL path to use for the current proxy request to node.
+ :param name: name of the NodeProxyOptions (required)
+ :type name: str
+ :param path: Path is the URL path to use for the current proxy request to node.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_post_node_proxy_with_http_info(name, **kwargs) # noqa: E501
@@ -5341,24 +6470,36 @@ def connect_post_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
connect POST requests to proxy of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_post_node_proxy_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the NodeProxyOptions (required)
- :param str path: Path is the URL path to use for the current proxy request to node.
+ :param name: name of the NodeProxyOptions (required)
+ :type name: str
+ :param path: Path is the URL path to use for the current proxy request to node.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -5372,7 +6513,10 @@ def connect_post_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -5385,8 +6529,7 @@ def connect_post_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_post_node_proxy`") # noqa: E501
collection_formats = {}
@@ -5396,10 +6539,10 @@ def connect_post_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'path' in local_var_params and local_var_params['path'] is not None: # noqa: E501
+ if local_var_params.get('path') is not None: # noqa: E501
query_params.append(('path', local_var_params['path'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -5412,6 +6555,11 @@ def connect_post_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/nodes/{name}/proxy', 'POST',
path_params,
@@ -5420,13 +6568,14 @@ def connect_post_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_post_node_proxy_with_path(self, name, path, **kwargs): # noqa: E501
"""connect_post_node_proxy_with_path # noqa: E501
@@ -5434,23 +6583,30 @@ def connect_post_node_proxy_with_path(self, name, path, **kwargs): # noqa: E501
connect POST requests to proxy of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_post_node_proxy_with_path(name, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the NodeProxyOptions (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the URL path to use for the current proxy request to node.
+ :param name: name of the NodeProxyOptions (required)
+ :type name: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the URL path to use for the current proxy request to node.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_post_node_proxy_with_path_with_http_info(name, path, **kwargs) # noqa: E501
@@ -5461,25 +6617,38 @@ def connect_post_node_proxy_with_path_with_http_info(self, name, path, **kwargs)
connect POST requests to proxy of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_post_node_proxy_with_path_with_http_info(name, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the NodeProxyOptions (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the URL path to use for the current proxy request to node.
+ :param name: name of the NodeProxyOptions (required)
+ :type name: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the URL path to use for the current proxy request to node.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -5494,7 +6663,10 @@ def connect_post_node_proxy_with_path_with_http_info(self, name, path, **kwargs)
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -5507,12 +6679,10 @@ def connect_post_node_proxy_with_path_with_http_info(self, name, path, **kwargs)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_post_node_proxy_with_path`") # noqa: E501
# verify the required parameter 'path' is set
- if self.api_client.client_side_validation and ('path' not in local_var_params or # noqa: E501
- local_var_params['path'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('path') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `path` when calling `connect_post_node_proxy_with_path`") # noqa: E501
collection_formats = {}
@@ -5524,10 +6694,10 @@ def connect_post_node_proxy_with_path_with_http_info(self, name, path, **kwargs)
path_params['path'] = local_var_params['path'] # noqa: E501
query_params = []
- if 'path2' in local_var_params and local_var_params['path2'] is not None: # noqa: E501
+ if local_var_params.get('path2') is not None: # noqa: E501
query_params.append(('path', local_var_params['path2'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -5540,6 +6710,11 @@ def connect_post_node_proxy_with_path_with_http_info(self, name, path, **kwargs)
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/nodes/{name}/proxy/{path}', 'POST',
path_params,
@@ -5548,13 +6723,14 @@ def connect_post_node_proxy_with_path_with_http_info(self, name, path, **kwargs)
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_put_namespaced_pod_proxy(self, name, namespace, **kwargs): # noqa: E501
"""connect_put_namespaced_pod_proxy # noqa: E501
@@ -5562,23 +6738,30 @@ def connect_put_namespaced_pod_proxy(self, name, namespace, **kwargs): # noqa:
connect PUT requests to proxy of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_put_namespaced_pod_proxy(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: Path is the URL path to use for the current proxy request to pod.
+ :param name: name of the PodProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: Path is the URL path to use for the current proxy request to pod.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_put_namespaced_pod_proxy_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -5589,25 +6772,38 @@ def connect_put_namespaced_pod_proxy_with_http_info(self, name, namespace, **kwa
connect PUT requests to proxy of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_put_namespaced_pod_proxy_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: Path is the URL path to use for the current proxy request to pod.
+ :param name: name of the PodProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: Path is the URL path to use for the current proxy request to pod.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -5622,7 +6818,10 @@ def connect_put_namespaced_pod_proxy_with_http_info(self, name, namespace, **kwa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -5635,12 +6834,10 @@ def connect_put_namespaced_pod_proxy_with_http_info(self, name, namespace, **kwa
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_put_namespaced_pod_proxy`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_put_namespaced_pod_proxy`") # noqa: E501
collection_formats = {}
@@ -5652,10 +6849,10 @@ def connect_put_namespaced_pod_proxy_with_http_info(self, name, namespace, **kwa
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'path' in local_var_params and local_var_params['path'] is not None: # noqa: E501
+ if local_var_params.get('path') is not None: # noqa: E501
query_params.append(('path', local_var_params['path'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -5668,6 +6865,11 @@ def connect_put_namespaced_pod_proxy_with_http_info(self, name, namespace, **kwa
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/proxy', 'PUT',
path_params,
@@ -5676,13 +6878,14 @@ def connect_put_namespaced_pod_proxy_with_http_info(self, name, namespace, **kwa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_put_namespaced_pod_proxy_with_path(self, name, namespace, path, **kwargs): # noqa: E501
"""connect_put_namespaced_pod_proxy_with_path # noqa: E501
@@ -5690,24 +6893,32 @@ def connect_put_namespaced_pod_proxy_with_path(self, name, namespace, path, **kw
connect PUT requests to proxy of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_put_namespaced_pod_proxy_with_path(name, namespace, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the URL path to use for the current proxy request to pod.
+ :param name: name of the PodProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the URL path to use for the current proxy request to pod.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_put_namespaced_pod_proxy_with_path_with_http_info(name, namespace, path, **kwargs) # noqa: E501
@@ -5718,26 +6929,40 @@ def connect_put_namespaced_pod_proxy_with_path_with_http_info(self, name, namesp
connect PUT requests to proxy of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_put_namespaced_pod_proxy_with_path_with_http_info(name, namespace, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the URL path to use for the current proxy request to pod.
+ :param name: name of the PodProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the URL path to use for the current proxy request to pod.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -5753,7 +6978,10 @@ def connect_put_namespaced_pod_proxy_with_path_with_http_info(self, name, namesp
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -5766,16 +6994,13 @@ def connect_put_namespaced_pod_proxy_with_path_with_http_info(self, name, namesp
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_put_namespaced_pod_proxy_with_path`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_put_namespaced_pod_proxy_with_path`") # noqa: E501
# verify the required parameter 'path' is set
- if self.api_client.client_side_validation and ('path' not in local_var_params or # noqa: E501
- local_var_params['path'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('path') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `path` when calling `connect_put_namespaced_pod_proxy_with_path`") # noqa: E501
collection_formats = {}
@@ -5789,10 +7014,10 @@ def connect_put_namespaced_pod_proxy_with_path_with_http_info(self, name, namesp
path_params['path'] = local_var_params['path'] # noqa: E501
query_params = []
- if 'path2' in local_var_params and local_var_params['path2'] is not None: # noqa: E501
+ if local_var_params.get('path2') is not None: # noqa: E501
query_params.append(('path', local_var_params['path2'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -5805,6 +7030,11 @@ def connect_put_namespaced_pod_proxy_with_path_with_http_info(self, name, namesp
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/proxy/{path}', 'PUT',
path_params,
@@ -5813,13 +7043,14 @@ def connect_put_namespaced_pod_proxy_with_path_with_http_info(self, name, namesp
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_put_namespaced_service_proxy(self, name, namespace, **kwargs): # noqa: E501
"""connect_put_namespaced_service_proxy # noqa: E501
@@ -5827,23 +7058,30 @@ def connect_put_namespaced_service_proxy(self, name, namespace, **kwargs): # no
connect PUT requests to proxy of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_put_namespaced_service_proxy(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :param name: name of the ServiceProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_put_namespaced_service_proxy_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -5854,25 +7092,38 @@ def connect_put_namespaced_service_proxy_with_http_info(self, name, namespace, *
connect PUT requests to proxy of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_put_namespaced_service_proxy_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :param name: name of the ServiceProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -5887,7 +7138,10 @@ def connect_put_namespaced_service_proxy_with_http_info(self, name, namespace, *
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -5900,12 +7154,10 @@ def connect_put_namespaced_service_proxy_with_http_info(self, name, namespace, *
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_put_namespaced_service_proxy`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_put_namespaced_service_proxy`") # noqa: E501
collection_formats = {}
@@ -5917,10 +7169,10 @@ def connect_put_namespaced_service_proxy_with_http_info(self, name, namespace, *
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'path' in local_var_params and local_var_params['path'] is not None: # noqa: E501
+ if local_var_params.get('path') is not None: # noqa: E501
query_params.append(('path', local_var_params['path'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -5933,6 +7185,11 @@ def connect_put_namespaced_service_proxy_with_http_info(self, name, namespace, *
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/services/{name}/proxy', 'PUT',
path_params,
@@ -5941,13 +7198,14 @@ def connect_put_namespaced_service_proxy_with_http_info(self, name, namespace, *
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_put_namespaced_service_proxy_with_path(self, name, namespace, path, **kwargs): # noqa: E501
"""connect_put_namespaced_service_proxy_with_path # noqa: E501
@@ -5955,24 +7213,32 @@ def connect_put_namespaced_service_proxy_with_path(self, name, namespace, path,
connect PUT requests to proxy of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_put_namespaced_service_proxy_with_path(name, namespace, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :param name: name of the ServiceProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_put_namespaced_service_proxy_with_path_with_http_info(name, namespace, path, **kwargs) # noqa: E501
@@ -5983,26 +7249,40 @@ def connect_put_namespaced_service_proxy_with_path_with_http_info(self, name, na
connect PUT requests to proxy of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_put_namespaced_service_proxy_with_path_with_http_info(name, namespace, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceProxyOptions (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :param name: name of the ServiceProxyOptions (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -6018,7 +7298,10 @@ def connect_put_namespaced_service_proxy_with_path_with_http_info(self, name, na
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -6031,16 +7314,13 @@ def connect_put_namespaced_service_proxy_with_path_with_http_info(self, name, na
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_put_namespaced_service_proxy_with_path`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `connect_put_namespaced_service_proxy_with_path`") # noqa: E501
# verify the required parameter 'path' is set
- if self.api_client.client_side_validation and ('path' not in local_var_params or # noqa: E501
- local_var_params['path'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('path') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `path` when calling `connect_put_namespaced_service_proxy_with_path`") # noqa: E501
collection_formats = {}
@@ -6054,10 +7334,10 @@ def connect_put_namespaced_service_proxy_with_path_with_http_info(self, name, na
path_params['path'] = local_var_params['path'] # noqa: E501
query_params = []
- if 'path2' in local_var_params and local_var_params['path2'] is not None: # noqa: E501
+ if local_var_params.get('path2') is not None: # noqa: E501
query_params.append(('path', local_var_params['path2'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -6070,6 +7350,11 @@ def connect_put_namespaced_service_proxy_with_path_with_http_info(self, name, na
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/services/{name}/proxy/{path}', 'PUT',
path_params,
@@ -6078,13 +7363,14 @@ def connect_put_namespaced_service_proxy_with_path_with_http_info(self, name, na
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_put_node_proxy(self, name, **kwargs): # noqa: E501
"""connect_put_node_proxy # noqa: E501
@@ -6092,22 +7378,28 @@ def connect_put_node_proxy(self, name, **kwargs): # noqa: E501
connect PUT requests to proxy of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_put_node_proxy(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the NodeProxyOptions (required)
- :param str path: Path is the URL path to use for the current proxy request to node.
+ :param name: name of the NodeProxyOptions (required)
+ :type name: str
+ :param path: Path is the URL path to use for the current proxy request to node.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_put_node_proxy_with_http_info(name, **kwargs) # noqa: E501
@@ -6118,24 +7410,36 @@ def connect_put_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
connect PUT requests to proxy of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_put_node_proxy_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the NodeProxyOptions (required)
- :param str path: Path is the URL path to use for the current proxy request to node.
+ :param name: name of the NodeProxyOptions (required)
+ :type name: str
+ :param path: Path is the URL path to use for the current proxy request to node.
+ :type path: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -6149,7 +7453,10 @@ def connect_put_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -6162,8 +7469,7 @@ def connect_put_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_put_node_proxy`") # noqa: E501
collection_formats = {}
@@ -6173,10 +7479,10 @@ def connect_put_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'path' in local_var_params and local_var_params['path'] is not None: # noqa: E501
+ if local_var_params.get('path') is not None: # noqa: E501
query_params.append(('path', local_var_params['path'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -6189,6 +7495,11 @@ def connect_put_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/nodes/{name}/proxy', 'PUT',
path_params,
@@ -6197,13 +7508,14 @@ def connect_put_node_proxy_with_http_info(self, name, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def connect_put_node_proxy_with_path(self, name, path, **kwargs): # noqa: E501
"""connect_put_node_proxy_with_path # noqa: E501
@@ -6211,23 +7523,30 @@ def connect_put_node_proxy_with_path(self, name, path, **kwargs): # noqa: E501
connect PUT requests to proxy of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_put_node_proxy_with_path(name, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the NodeProxyOptions (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the URL path to use for the current proxy request to node.
+ :param name: name of the NodeProxyOptions (required)
+ :type name: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the URL path to use for the current proxy request to node.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.connect_put_node_proxy_with_path_with_http_info(name, path, **kwargs) # noqa: E501
@@ -6238,25 +7557,38 @@ def connect_put_node_proxy_with_path_with_http_info(self, name, path, **kwargs):
connect PUT requests to proxy of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.connect_put_node_proxy_with_path_with_http_info(name, path, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the NodeProxyOptions (required)
- :param str path: path to the resource (required)
- :param str path2: Path is the URL path to use for the current proxy request to node.
+ :param name: name of the NodeProxyOptions (required)
+ :type name: str
+ :param path: path to the resource (required)
+ :type path: str
+ :param path2: Path is the URL path to use for the current proxy request to node.
+ :type path2: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -6271,7 +7603,10 @@ def connect_put_node_proxy_with_path_with_http_info(self, name, path, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -6284,12 +7619,10 @@ def connect_put_node_proxy_with_path_with_http_info(self, name, path, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `connect_put_node_proxy_with_path`") # noqa: E501
# verify the required parameter 'path' is set
- if self.api_client.client_side_validation and ('path' not in local_var_params or # noqa: E501
- local_var_params['path'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('path') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `path` when calling `connect_put_node_proxy_with_path`") # noqa: E501
collection_formats = {}
@@ -6301,10 +7634,10 @@ def connect_put_node_proxy_with_path_with_http_info(self, name, path, **kwargs):
path_params['path'] = local_var_params['path'] # noqa: E501
query_params = []
- if 'path2' in local_var_params and local_var_params['path2'] is not None: # noqa: E501
+ if local_var_params.get('path2') is not None: # noqa: E501
query_params.append(('path', local_var_params['path2'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -6317,6 +7650,11 @@ def connect_put_node_proxy_with_path_with_http_info(self, name, path, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/nodes/{name}/proxy/{path}', 'PUT',
path_params,
@@ -6325,13 +7663,14 @@ def connect_put_node_proxy_with_path_with_http_info(self, name, path, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_namespace(self, body, **kwargs): # noqa: E501
"""create_namespace # noqa: E501
@@ -6339,25 +7678,34 @@ def create_namespace(self, body, **kwargs): # noqa: E501
create a Namespace # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespace(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1Namespace body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1Namespace
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Namespace
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Namespace
"""
kwargs['_return_http_data_only'] = True
return self.create_namespace_with_http_info(body, **kwargs) # noqa: E501
@@ -6368,27 +7716,42 @@ def create_namespace_with_http_info(self, body, **kwargs): # noqa: E501
create a Namespace # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespace_with_http_info(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1Namespace body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1Namespace
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Namespace, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Namespace, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -6405,7 +7768,10 @@ def create_namespace_with_http_info(self, body, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -6418,8 +7784,7 @@ def create_namespace_with_http_info(self, body, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespace`") # noqa: E501
collection_formats = {}
@@ -6427,16 +7792,16 @@ def create_namespace_with_http_info(self, body, **kwargs): # noqa: E501
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -6451,6 +7816,13 @@ def create_namespace_with_http_info(self, body, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Namespace",
+ 201: "V1Namespace",
+ 202: "V1Namespace",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces', 'POST',
path_params,
@@ -6459,13 +7831,14 @@ def create_namespace_with_http_info(self, body, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Namespace', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_namespaced_binding(self, namespace, body, **kwargs): # noqa: E501
"""create_namespaced_binding # noqa: E501
@@ -6473,26 +7846,36 @@ def create_namespaced_binding(self, namespace, body, **kwargs): # noqa: E501
create a Binding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_binding(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Binding body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Binding
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Binding
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Binding
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_binding_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -6503,28 +7886,44 @@ def create_namespaced_binding_with_http_info(self, namespace, body, **kwargs):
create a Binding # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_binding_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Binding body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Binding
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Binding, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Binding, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -6542,7 +7941,10 @@ def create_namespaced_binding_with_http_info(self, namespace, body, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -6555,12 +7957,10 @@ def create_namespaced_binding_with_http_info(self, namespace, body, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_binding`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_binding`") # noqa: E501
collection_formats = {}
@@ -6570,16 +7970,16 @@ def create_namespaced_binding_with_http_info(self, namespace, body, **kwargs):
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -6594,6 +7994,13 @@ def create_namespaced_binding_with_http_info(self, namespace, body, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Binding",
+ 201: "V1Binding",
+ 202: "V1Binding",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/bindings', 'POST',
path_params,
@@ -6602,13 +8009,14 @@ def create_namespaced_binding_with_http_info(self, namespace, body, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Binding', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_namespaced_config_map(self, namespace, body, **kwargs): # noqa: E501
"""create_namespaced_config_map # noqa: E501
@@ -6616,26 +8024,36 @@ def create_namespaced_config_map(self, namespace, body, **kwargs): # noqa: E501
create a ConfigMap # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_config_map(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ConfigMap body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ConfigMap
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ConfigMap
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ConfigMap
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_config_map_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -6646,28 +8064,44 @@ def create_namespaced_config_map_with_http_info(self, namespace, body, **kwargs)
create a ConfigMap # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_config_map_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ConfigMap body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ConfigMap
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ConfigMap, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ConfigMap, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -6685,7 +8119,10 @@ def create_namespaced_config_map_with_http_info(self, namespace, body, **kwargs)
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -6698,12 +8135,10 @@ def create_namespaced_config_map_with_http_info(self, namespace, body, **kwargs)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_config_map`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_config_map`") # noqa: E501
collection_formats = {}
@@ -6713,16 +8148,16 @@ def create_namespaced_config_map_with_http_info(self, namespace, body, **kwargs)
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -6737,6 +8172,13 @@ def create_namespaced_config_map_with_http_info(self, namespace, body, **kwargs)
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ConfigMap",
+ 201: "V1ConfigMap",
+ 202: "V1ConfigMap",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/configmaps', 'POST',
path_params,
@@ -6745,13 +8187,14 @@ def create_namespaced_config_map_with_http_info(self, namespace, body, **kwargs)
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ConfigMap', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_namespaced_endpoints(self, namespace, body, **kwargs): # noqa: E501
"""create_namespaced_endpoints # noqa: E501
@@ -6759,26 +8202,36 @@ def create_namespaced_endpoints(self, namespace, body, **kwargs): # noqa: E501
create Endpoints # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_endpoints(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Endpoints body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Endpoints
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Endpoints
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Endpoints
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_endpoints_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -6789,28 +8242,44 @@ def create_namespaced_endpoints_with_http_info(self, namespace, body, **kwargs):
create Endpoints # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_endpoints_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Endpoints body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Endpoints
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Endpoints, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Endpoints, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -6828,7 +8297,10 @@ def create_namespaced_endpoints_with_http_info(self, namespace, body, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -6841,12 +8313,10 @@ def create_namespaced_endpoints_with_http_info(self, namespace, body, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_endpoints`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_endpoints`") # noqa: E501
collection_formats = {}
@@ -6856,16 +8326,16 @@ def create_namespaced_endpoints_with_http_info(self, namespace, body, **kwargs):
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -6880,6 +8350,13 @@ def create_namespaced_endpoints_with_http_info(self, namespace, body, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Endpoints",
+ 201: "V1Endpoints",
+ 202: "V1Endpoints",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/endpoints', 'POST',
path_params,
@@ -6888,13 +8365,14 @@ def create_namespaced_endpoints_with_http_info(self, namespace, body, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Endpoints', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_namespaced_event(self, namespace, body, **kwargs): # noqa: E501
"""create_namespaced_event # noqa: E501
@@ -6902,26 +8380,36 @@ def create_namespaced_event(self, namespace, body, **kwargs): # noqa: E501
create an Event # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_event(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param CoreV1Event body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: CoreV1Event
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: CoreV1Event
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: CoreV1Event
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_event_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -6932,28 +8420,44 @@ def create_namespaced_event_with_http_info(self, namespace, body, **kwargs): #
create an Event # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_event_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param CoreV1Event body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: CoreV1Event
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(CoreV1Event, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(CoreV1Event, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -6971,7 +8475,10 @@ def create_namespaced_event_with_http_info(self, namespace, body, **kwargs): #
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -6984,12 +8491,10 @@ def create_namespaced_event_with_http_info(self, namespace, body, **kwargs): #
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_event`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_event`") # noqa: E501
collection_formats = {}
@@ -6999,16 +8504,16 @@ def create_namespaced_event_with_http_info(self, namespace, body, **kwargs): #
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -7023,6 +8528,13 @@ def create_namespaced_event_with_http_info(self, namespace, body, **kwargs): #
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "CoreV1Event",
+ 201: "CoreV1Event",
+ 202: "CoreV1Event",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/events', 'POST',
path_params,
@@ -7031,13 +8543,14 @@ def create_namespaced_event_with_http_info(self, namespace, body, **kwargs): #
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='CoreV1Event', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_namespaced_limit_range(self, namespace, body, **kwargs): # noqa: E501
"""create_namespaced_limit_range # noqa: E501
@@ -7045,26 +8558,36 @@ def create_namespaced_limit_range(self, namespace, body, **kwargs): # noqa: E50
create a LimitRange # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_limit_range(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1LimitRange body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1LimitRange
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1LimitRange
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1LimitRange
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_limit_range_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -7075,28 +8598,44 @@ def create_namespaced_limit_range_with_http_info(self, namespace, body, **kwargs
create a LimitRange # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_limit_range_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1LimitRange body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1LimitRange
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1LimitRange, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1LimitRange, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -7114,7 +8653,10 @@ def create_namespaced_limit_range_with_http_info(self, namespace, body, **kwargs
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -7127,12 +8669,10 @@ def create_namespaced_limit_range_with_http_info(self, namespace, body, **kwargs
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_limit_range`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_limit_range`") # noqa: E501
collection_formats = {}
@@ -7142,16 +8682,16 @@ def create_namespaced_limit_range_with_http_info(self, namespace, body, **kwargs
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -7166,6 +8706,13 @@ def create_namespaced_limit_range_with_http_info(self, namespace, body, **kwargs
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1LimitRange",
+ 201: "V1LimitRange",
+ 202: "V1LimitRange",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/limitranges', 'POST',
path_params,
@@ -7174,13 +8721,14 @@ def create_namespaced_limit_range_with_http_info(self, namespace, body, **kwargs
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1LimitRange', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_namespaced_persistent_volume_claim(self, namespace, body, **kwargs): # noqa: E501
"""create_namespaced_persistent_volume_claim # noqa: E501
@@ -7188,26 +8736,36 @@ def create_namespaced_persistent_volume_claim(self, namespace, body, **kwargs):
create a PersistentVolumeClaim # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_persistent_volume_claim(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1PersistentVolumeClaim body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1PersistentVolumeClaim
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1PersistentVolumeClaim
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1PersistentVolumeClaim
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_persistent_volume_claim_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -7218,28 +8776,44 @@ def create_namespaced_persistent_volume_claim_with_http_info(self, namespace, bo
create a PersistentVolumeClaim # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_persistent_volume_claim_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1PersistentVolumeClaim body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1PersistentVolumeClaim
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1PersistentVolumeClaim, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1PersistentVolumeClaim, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -7257,7 +8831,10 @@ def create_namespaced_persistent_volume_claim_with_http_info(self, namespace, bo
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -7270,12 +8847,10 @@ def create_namespaced_persistent_volume_claim_with_http_info(self, namespace, bo
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_persistent_volume_claim`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_persistent_volume_claim`") # noqa: E501
collection_formats = {}
@@ -7285,16 +8860,16 @@ def create_namespaced_persistent_volume_claim_with_http_info(self, namespace, bo
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -7309,6 +8884,13 @@ def create_namespaced_persistent_volume_claim_with_http_info(self, namespace, bo
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1PersistentVolumeClaim",
+ 201: "V1PersistentVolumeClaim",
+ 202: "V1PersistentVolumeClaim",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/persistentvolumeclaims', 'POST',
path_params,
@@ -7317,13 +8899,14 @@ def create_namespaced_persistent_volume_claim_with_http_info(self, namespace, bo
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1PersistentVolumeClaim', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_namespaced_pod(self, namespace, body, **kwargs): # noqa: E501
"""create_namespaced_pod # noqa: E501
@@ -7331,26 +8914,36 @@ def create_namespaced_pod(self, namespace, body, **kwargs): # noqa: E501
create a Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_pod(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Pod body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Pod
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Pod
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Pod
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_pod_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -7361,28 +8954,44 @@ def create_namespaced_pod_with_http_info(self, namespace, body, **kwargs): # no
create a Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_pod_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Pod body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Pod
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Pod, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Pod, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -7400,7 +9009,10 @@ def create_namespaced_pod_with_http_info(self, namespace, body, **kwargs): # no
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -7413,12 +9025,10 @@ def create_namespaced_pod_with_http_info(self, namespace, body, **kwargs): # no
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_pod`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_pod`") # noqa: E501
collection_formats = {}
@@ -7428,16 +9038,16 @@ def create_namespaced_pod_with_http_info(self, namespace, body, **kwargs): # no
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -7452,6 +9062,13 @@ def create_namespaced_pod_with_http_info(self, namespace, body, **kwargs): # no
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Pod",
+ 201: "V1Pod",
+ 202: "V1Pod",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods', 'POST',
path_params,
@@ -7460,13 +9077,14 @@ def create_namespaced_pod_with_http_info(self, namespace, body, **kwargs): # no
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Pod', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_namespaced_pod_binding(self, name, namespace, body, **kwargs): # noqa: E501
"""create_namespaced_pod_binding # noqa: E501
@@ -7474,27 +9092,38 @@ def create_namespaced_pod_binding(self, name, namespace, body, **kwargs): # noq
create binding of a Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_pod_binding(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Binding (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Binding body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Binding (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Binding
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Binding
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Binding
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_pod_binding_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -7505,29 +9134,46 @@ def create_namespaced_pod_binding_with_http_info(self, name, namespace, body, **
create binding of a Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_pod_binding_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Binding (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Binding body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Binding (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Binding
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Binding, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Binding, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -7546,7 +9192,10 @@ def create_namespaced_pod_binding_with_http_info(self, name, namespace, body, **
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -7559,16 +9208,13 @@ def create_namespaced_pod_binding_with_http_info(self, name, namespace, body, **
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `create_namespaced_pod_binding`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_pod_binding`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_pod_binding`") # noqa: E501
collection_formats = {}
@@ -7580,16 +9226,16 @@ def create_namespaced_pod_binding_with_http_info(self, name, namespace, body, **
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -7604,6 +9250,13 @@ def create_namespaced_pod_binding_with_http_info(self, name, namespace, body, **
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Binding",
+ 201: "V1Binding",
+ 202: "V1Binding",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/binding', 'POST',
path_params,
@@ -7612,13 +9265,14 @@ def create_namespaced_pod_binding_with_http_info(self, name, namespace, body, **
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Binding', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_namespaced_pod_eviction(self, name, namespace, body, **kwargs): # noqa: E501
"""create_namespaced_pod_eviction # noqa: E501
@@ -7626,27 +9280,38 @@ def create_namespaced_pod_eviction(self, name, namespace, body, **kwargs): # no
create eviction of a Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_pod_eviction(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Eviction (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Eviction body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Eviction (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Eviction
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Eviction
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Eviction
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_pod_eviction_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -7657,29 +9322,46 @@ def create_namespaced_pod_eviction_with_http_info(self, name, namespace, body, *
create eviction of a Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_pod_eviction_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Eviction (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Eviction body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Eviction (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Eviction
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Eviction, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Eviction, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -7698,7 +9380,10 @@ def create_namespaced_pod_eviction_with_http_info(self, name, namespace, body, *
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -7711,16 +9396,13 @@ def create_namespaced_pod_eviction_with_http_info(self, name, namespace, body, *
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `create_namespaced_pod_eviction`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_pod_eviction`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_pod_eviction`") # noqa: E501
collection_formats = {}
@@ -7732,16 +9414,16 @@ def create_namespaced_pod_eviction_with_http_info(self, name, namespace, body, *
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -7756,6 +9438,13 @@ def create_namespaced_pod_eviction_with_http_info(self, name, namespace, body, *
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Eviction",
+ 201: "V1Eviction",
+ 202: "V1Eviction",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/eviction', 'POST',
path_params,
@@ -7764,13 +9453,14 @@ def create_namespaced_pod_eviction_with_http_info(self, name, namespace, body, *
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Eviction', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_namespaced_pod_template(self, namespace, body, **kwargs): # noqa: E501
"""create_namespaced_pod_template # noqa: E501
@@ -7778,26 +9468,36 @@ def create_namespaced_pod_template(self, namespace, body, **kwargs): # noqa: E5
create a PodTemplate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_pod_template(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1PodTemplate body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1PodTemplate
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1PodTemplate
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1PodTemplate
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_pod_template_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -7808,28 +9508,44 @@ def create_namespaced_pod_template_with_http_info(self, namespace, body, **kwarg
create a PodTemplate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_pod_template_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1PodTemplate body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1PodTemplate
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1PodTemplate, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1PodTemplate, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -7847,7 +9563,10 @@ def create_namespaced_pod_template_with_http_info(self, namespace, body, **kwarg
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -7860,12 +9579,10 @@ def create_namespaced_pod_template_with_http_info(self, namespace, body, **kwarg
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_pod_template`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_pod_template`") # noqa: E501
collection_formats = {}
@@ -7875,16 +9592,16 @@ def create_namespaced_pod_template_with_http_info(self, namespace, body, **kwarg
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -7899,6 +9616,13 @@ def create_namespaced_pod_template_with_http_info(self, namespace, body, **kwarg
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1PodTemplate",
+ 201: "V1PodTemplate",
+ 202: "V1PodTemplate",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/podtemplates', 'POST',
path_params,
@@ -7907,13 +9631,14 @@ def create_namespaced_pod_template_with_http_info(self, namespace, body, **kwarg
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1PodTemplate', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_namespaced_replication_controller(self, namespace, body, **kwargs): # noqa: E501
"""create_namespaced_replication_controller # noqa: E501
@@ -7921,26 +9646,36 @@ def create_namespaced_replication_controller(self, namespace, body, **kwargs):
create a ReplicationController # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_replication_controller(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ReplicationController body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ReplicationController
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ReplicationController
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ReplicationController
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_replication_controller_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -7951,28 +9686,44 @@ def create_namespaced_replication_controller_with_http_info(self, namespace, bod
create a ReplicationController # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_replication_controller_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ReplicationController body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ReplicationController
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ReplicationController, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ReplicationController, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -7990,7 +9741,10 @@ def create_namespaced_replication_controller_with_http_info(self, namespace, bod
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -8003,12 +9757,10 @@ def create_namespaced_replication_controller_with_http_info(self, namespace, bod
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_replication_controller`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_replication_controller`") # noqa: E501
collection_formats = {}
@@ -8018,16 +9770,16 @@ def create_namespaced_replication_controller_with_http_info(self, namespace, bod
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -8042,6 +9794,13 @@ def create_namespaced_replication_controller_with_http_info(self, namespace, bod
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ReplicationController",
+ 201: "V1ReplicationController",
+ 202: "V1ReplicationController",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/replicationcontrollers', 'POST',
path_params,
@@ -8050,13 +9809,14 @@ def create_namespaced_replication_controller_with_http_info(self, namespace, bod
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ReplicationController', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_namespaced_resource_quota(self, namespace, body, **kwargs): # noqa: E501
"""create_namespaced_resource_quota # noqa: E501
@@ -8064,26 +9824,36 @@ def create_namespaced_resource_quota(self, namespace, body, **kwargs): # noqa:
create a ResourceQuota # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_resource_quota(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ResourceQuota body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ResourceQuota
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ResourceQuota
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ResourceQuota
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_resource_quota_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -8094,28 +9864,44 @@ def create_namespaced_resource_quota_with_http_info(self, namespace, body, **kwa
create a ResourceQuota # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_resource_quota_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ResourceQuota body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ResourceQuota
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ResourceQuota, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ResourceQuota, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -8133,7 +9919,10 @@ def create_namespaced_resource_quota_with_http_info(self, namespace, body, **kwa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -8146,12 +9935,10 @@ def create_namespaced_resource_quota_with_http_info(self, namespace, body, **kwa
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_resource_quota`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_resource_quota`") # noqa: E501
collection_formats = {}
@@ -8161,16 +9948,16 @@ def create_namespaced_resource_quota_with_http_info(self, namespace, body, **kwa
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -8185,6 +9972,13 @@ def create_namespaced_resource_quota_with_http_info(self, namespace, body, **kwa
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ResourceQuota",
+ 201: "V1ResourceQuota",
+ 202: "V1ResourceQuota",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/resourcequotas', 'POST',
path_params,
@@ -8193,13 +9987,14 @@ def create_namespaced_resource_quota_with_http_info(self, namespace, body, **kwa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ResourceQuota', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_namespaced_secret(self, namespace, body, **kwargs): # noqa: E501
"""create_namespaced_secret # noqa: E501
@@ -8207,26 +10002,36 @@ def create_namespaced_secret(self, namespace, body, **kwargs): # noqa: E501
create a Secret # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_secret(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Secret body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Secret
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Secret
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Secret
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_secret_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -8237,28 +10042,44 @@ def create_namespaced_secret_with_http_info(self, namespace, body, **kwargs): #
create a Secret # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_secret_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Secret body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Secret
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Secret, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Secret, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -8276,7 +10097,10 @@ def create_namespaced_secret_with_http_info(self, namespace, body, **kwargs): #
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -8289,12 +10113,10 @@ def create_namespaced_secret_with_http_info(self, namespace, body, **kwargs): #
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_secret`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_secret`") # noqa: E501
collection_formats = {}
@@ -8304,16 +10126,16 @@ def create_namespaced_secret_with_http_info(self, namespace, body, **kwargs): #
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -8328,6 +10150,13 @@ def create_namespaced_secret_with_http_info(self, namespace, body, **kwargs): #
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Secret",
+ 201: "V1Secret",
+ 202: "V1Secret",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/secrets', 'POST',
path_params,
@@ -8336,13 +10165,14 @@ def create_namespaced_secret_with_http_info(self, namespace, body, **kwargs): #
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Secret', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_namespaced_service(self, namespace, body, **kwargs): # noqa: E501
"""create_namespaced_service # noqa: E501
@@ -8350,26 +10180,36 @@ def create_namespaced_service(self, namespace, body, **kwargs): # noqa: E501
create a Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_service(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Service body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Service
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Service
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Service
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_service_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -8380,28 +10220,44 @@ def create_namespaced_service_with_http_info(self, namespace, body, **kwargs):
create a Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_service_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Service body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Service
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Service, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Service, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -8419,7 +10275,10 @@ def create_namespaced_service_with_http_info(self, namespace, body, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -8432,12 +10291,10 @@ def create_namespaced_service_with_http_info(self, namespace, body, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_service`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_service`") # noqa: E501
collection_formats = {}
@@ -8447,16 +10304,16 @@ def create_namespaced_service_with_http_info(self, namespace, body, **kwargs):
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -8471,6 +10328,13 @@ def create_namespaced_service_with_http_info(self, namespace, body, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Service",
+ 201: "V1Service",
+ 202: "V1Service",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/services', 'POST',
path_params,
@@ -8479,13 +10343,14 @@ def create_namespaced_service_with_http_info(self, namespace, body, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Service', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_namespaced_service_account(self, namespace, body, **kwargs): # noqa: E501
"""create_namespaced_service_account # noqa: E501
@@ -8493,26 +10358,36 @@ def create_namespaced_service_account(self, namespace, body, **kwargs): # noqa:
create a ServiceAccount # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_service_account(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ServiceAccount body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ServiceAccount
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ServiceAccount
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ServiceAccount
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_service_account_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -8523,28 +10398,44 @@ def create_namespaced_service_account_with_http_info(self, namespace, body, **kw
create a ServiceAccount # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_service_account_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ServiceAccount body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ServiceAccount
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ServiceAccount, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ServiceAccount, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -8562,7 +10453,10 @@ def create_namespaced_service_account_with_http_info(self, namespace, body, **kw
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -8575,12 +10469,10 @@ def create_namespaced_service_account_with_http_info(self, namespace, body, **kw
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_service_account`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_service_account`") # noqa: E501
collection_formats = {}
@@ -8590,16 +10482,16 @@ def create_namespaced_service_account_with_http_info(self, namespace, body, **kw
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -8614,6 +10506,13 @@ def create_namespaced_service_account_with_http_info(self, namespace, body, **kw
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ServiceAccount",
+ 201: "V1ServiceAccount",
+ 202: "V1ServiceAccount",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/serviceaccounts', 'POST',
path_params,
@@ -8622,13 +10521,14 @@ def create_namespaced_service_account_with_http_info(self, namespace, body, **kw
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ServiceAccount', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_namespaced_service_account_token(self, name, namespace, body, **kwargs): # noqa: E501
"""create_namespaced_service_account_token # noqa: E501
@@ -8636,27 +10536,38 @@ def create_namespaced_service_account_token(self, name, namespace, body, **kwarg
create token of a ServiceAccount # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_service_account_token(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the TokenRequest (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param AuthenticationV1TokenRequest body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the TokenRequest (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: AuthenticationV1TokenRequest
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: AuthenticationV1TokenRequest
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: AuthenticationV1TokenRequest
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_service_account_token_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -8667,29 +10578,46 @@ def create_namespaced_service_account_token_with_http_info(self, name, namespace
create token of a ServiceAccount # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_service_account_token_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the TokenRequest (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param AuthenticationV1TokenRequest body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the TokenRequest (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: AuthenticationV1TokenRequest
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(AuthenticationV1TokenRequest, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(AuthenticationV1TokenRequest, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -8708,7 +10636,10 @@ def create_namespaced_service_account_token_with_http_info(self, name, namespace
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -8721,16 +10652,13 @@ def create_namespaced_service_account_token_with_http_info(self, name, namespace
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `create_namespaced_service_account_token`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_service_account_token`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_service_account_token`") # noqa: E501
collection_formats = {}
@@ -8742,16 +10670,16 @@ def create_namespaced_service_account_token_with_http_info(self, name, namespace
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -8766,6 +10694,13 @@ def create_namespaced_service_account_token_with_http_info(self, name, namespace
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "AuthenticationV1TokenRequest",
+ 201: "AuthenticationV1TokenRequest",
+ 202: "AuthenticationV1TokenRequest",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/serviceaccounts/{name}/token', 'POST',
path_params,
@@ -8774,13 +10709,14 @@ def create_namespaced_service_account_token_with_http_info(self, name, namespace
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='AuthenticationV1TokenRequest', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_node(self, body, **kwargs): # noqa: E501
"""create_node # noqa: E501
@@ -8788,25 +10724,34 @@ def create_node(self, body, **kwargs): # noqa: E501
create a Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_node(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1Node body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1Node
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Node
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Node
"""
kwargs['_return_http_data_only'] = True
return self.create_node_with_http_info(body, **kwargs) # noqa: E501
@@ -8817,27 +10762,42 @@ def create_node_with_http_info(self, body, **kwargs): # noqa: E501
create a Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_node_with_http_info(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1Node body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1Node
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Node, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Node, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -8854,7 +10814,10 @@ def create_node_with_http_info(self, body, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -8867,8 +10830,7 @@ def create_node_with_http_info(self, body, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_node`") # noqa: E501
collection_formats = {}
@@ -8876,16 +10838,16 @@ def create_node_with_http_info(self, body, **kwargs): # noqa: E501
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -8900,6 +10862,13 @@ def create_node_with_http_info(self, body, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Node",
+ 201: "V1Node",
+ 202: "V1Node",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/nodes', 'POST',
path_params,
@@ -8908,13 +10877,14 @@ def create_node_with_http_info(self, body, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Node', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_persistent_volume(self, body, **kwargs): # noqa: E501
"""create_persistent_volume # noqa: E501
@@ -8922,25 +10892,34 @@ def create_persistent_volume(self, body, **kwargs): # noqa: E501
create a PersistentVolume # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_persistent_volume(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1PersistentVolume body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1PersistentVolume
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1PersistentVolume
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1PersistentVolume
"""
kwargs['_return_http_data_only'] = True
return self.create_persistent_volume_with_http_info(body, **kwargs) # noqa: E501
@@ -8951,27 +10930,42 @@ def create_persistent_volume_with_http_info(self, body, **kwargs): # noqa: E501
create a PersistentVolume # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_persistent_volume_with_http_info(body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param V1PersistentVolume body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param body: (required)
+ :type body: V1PersistentVolume
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1PersistentVolume, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1PersistentVolume, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -8988,7 +10982,10 @@ def create_persistent_volume_with_http_info(self, body, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -9001,8 +10998,7 @@ def create_persistent_volume_with_http_info(self, body, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_persistent_volume`") # noqa: E501
collection_formats = {}
@@ -9010,16 +11006,16 @@ def create_persistent_volume_with_http_info(self, body, **kwargs): # noqa: E501
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -9034,6 +11030,13 @@ def create_persistent_volume_with_http_info(self, body, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1PersistentVolume",
+ 201: "V1PersistentVolume",
+ 202: "V1PersistentVolume",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/persistentvolumes', 'POST',
path_params,
@@ -9042,13 +11045,14 @@ def create_persistent_volume_with_http_info(self, body, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1PersistentVolume', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_namespaced_config_map(self, namespace, **kwargs): # noqa: E501
"""delete_collection_namespaced_config_map # noqa: E501
@@ -9056,36 +11060,56 @@ def delete_collection_namespaced_config_map(self, namespace, **kwargs): # noqa:
delete collection of ConfigMap # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_config_map(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_namespaced_config_map_with_http_info(namespace, **kwargs) # noqa: E501
@@ -9096,38 +11120,64 @@ def delete_collection_namespaced_config_map_with_http_info(self, namespace, **kw
delete collection of ConfigMap # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_config_map_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -9155,7 +11205,10 @@ def delete_collection_namespaced_config_map_with_http_info(self, namespace, **kw
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -9168,8 +11221,7 @@ def delete_collection_namespaced_config_map_with_http_info(self, namespace, **kw
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_config_map`") # noqa: E501
collection_formats = {}
@@ -9179,36 +11231,36 @@ def delete_collection_namespaced_config_map_with_http_info(self, namespace, **kw
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -9223,6 +11275,11 @@ def delete_collection_namespaced_config_map_with_http_info(self, namespace, **kw
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/configmaps', 'DELETE',
path_params,
@@ -9231,13 +11288,14 @@ def delete_collection_namespaced_config_map_with_http_info(self, namespace, **kw
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_namespaced_endpoints(self, namespace, **kwargs): # noqa: E501
"""delete_collection_namespaced_endpoints # noqa: E501
@@ -9245,36 +11303,56 @@ def delete_collection_namespaced_endpoints(self, namespace, **kwargs): # noqa:
delete collection of Endpoints # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_endpoints(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_namespaced_endpoints_with_http_info(namespace, **kwargs) # noqa: E501
@@ -9285,38 +11363,64 @@ def delete_collection_namespaced_endpoints_with_http_info(self, namespace, **kwa
delete collection of Endpoints # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_endpoints_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -9344,7 +11448,10 @@ def delete_collection_namespaced_endpoints_with_http_info(self, namespace, **kwa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -9357,8 +11464,7 @@ def delete_collection_namespaced_endpoints_with_http_info(self, namespace, **kwa
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_endpoints`") # noqa: E501
collection_formats = {}
@@ -9368,36 +11474,36 @@ def delete_collection_namespaced_endpoints_with_http_info(self, namespace, **kwa
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -9412,6 +11518,11 @@ def delete_collection_namespaced_endpoints_with_http_info(self, namespace, **kwa
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/endpoints', 'DELETE',
path_params,
@@ -9420,13 +11531,14 @@ def delete_collection_namespaced_endpoints_with_http_info(self, namespace, **kwa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_namespaced_event(self, namespace, **kwargs): # noqa: E501
"""delete_collection_namespaced_event # noqa: E501
@@ -9434,36 +11546,56 @@ def delete_collection_namespaced_event(self, namespace, **kwargs): # noqa: E501
delete collection of Event # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_event(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_namespaced_event_with_http_info(namespace, **kwargs) # noqa: E501
@@ -9474,38 +11606,64 @@ def delete_collection_namespaced_event_with_http_info(self, namespace, **kwargs)
delete collection of Event # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_event_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -9533,7 +11691,10 @@ def delete_collection_namespaced_event_with_http_info(self, namespace, **kwargs)
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -9546,8 +11707,7 @@ def delete_collection_namespaced_event_with_http_info(self, namespace, **kwargs)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_event`") # noqa: E501
collection_formats = {}
@@ -9557,36 +11717,36 @@ def delete_collection_namespaced_event_with_http_info(self, namespace, **kwargs)
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -9601,6 +11761,11 @@ def delete_collection_namespaced_event_with_http_info(self, namespace, **kwargs)
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/events', 'DELETE',
path_params,
@@ -9609,13 +11774,14 @@ def delete_collection_namespaced_event_with_http_info(self, namespace, **kwargs)
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_namespaced_limit_range(self, namespace, **kwargs): # noqa: E501
"""delete_collection_namespaced_limit_range # noqa: E501
@@ -9623,36 +11789,56 @@ def delete_collection_namespaced_limit_range(self, namespace, **kwargs): # noqa
delete collection of LimitRange # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_limit_range(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_namespaced_limit_range_with_http_info(namespace, **kwargs) # noqa: E501
@@ -9663,38 +11849,64 @@ def delete_collection_namespaced_limit_range_with_http_info(self, namespace, **k
delete collection of LimitRange # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_limit_range_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -9722,7 +11934,10 @@ def delete_collection_namespaced_limit_range_with_http_info(self, namespace, **k
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -9735,8 +11950,7 @@ def delete_collection_namespaced_limit_range_with_http_info(self, namespace, **k
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_limit_range`") # noqa: E501
collection_formats = {}
@@ -9746,36 +11960,36 @@ def delete_collection_namespaced_limit_range_with_http_info(self, namespace, **k
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -9790,6 +12004,11 @@ def delete_collection_namespaced_limit_range_with_http_info(self, namespace, **k
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/limitranges', 'DELETE',
path_params,
@@ -9798,13 +12017,14 @@ def delete_collection_namespaced_limit_range_with_http_info(self, namespace, **k
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_namespaced_persistent_volume_claim(self, namespace, **kwargs): # noqa: E501
"""delete_collection_namespaced_persistent_volume_claim # noqa: E501
@@ -9812,36 +12032,56 @@ def delete_collection_namespaced_persistent_volume_claim(self, namespace, **kwar
delete collection of PersistentVolumeClaim # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_persistent_volume_claim(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_namespaced_persistent_volume_claim_with_http_info(namespace, **kwargs) # noqa: E501
@@ -9852,38 +12092,64 @@ def delete_collection_namespaced_persistent_volume_claim_with_http_info(self, na
delete collection of PersistentVolumeClaim # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_persistent_volume_claim_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -9911,7 +12177,10 @@ def delete_collection_namespaced_persistent_volume_claim_with_http_info(self, na
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -9924,8 +12193,7 @@ def delete_collection_namespaced_persistent_volume_claim_with_http_info(self, na
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_persistent_volume_claim`") # noqa: E501
collection_formats = {}
@@ -9935,36 +12203,36 @@ def delete_collection_namespaced_persistent_volume_claim_with_http_info(self, na
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -9979,6 +12247,11 @@ def delete_collection_namespaced_persistent_volume_claim_with_http_info(self, na
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/persistentvolumeclaims', 'DELETE',
path_params,
@@ -9987,13 +12260,14 @@ def delete_collection_namespaced_persistent_volume_claim_with_http_info(self, na
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_namespaced_pod(self, namespace, **kwargs): # noqa: E501
"""delete_collection_namespaced_pod # noqa: E501
@@ -10001,36 +12275,56 @@ def delete_collection_namespaced_pod(self, namespace, **kwargs): # noqa: E501
delete collection of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_pod(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_namespaced_pod_with_http_info(namespace, **kwargs) # noqa: E501
@@ -10041,38 +12335,64 @@ def delete_collection_namespaced_pod_with_http_info(self, namespace, **kwargs):
delete collection of Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_pod_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -10100,7 +12420,10 @@ def delete_collection_namespaced_pod_with_http_info(self, namespace, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -10113,8 +12436,7 @@ def delete_collection_namespaced_pod_with_http_info(self, namespace, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_pod`") # noqa: E501
collection_formats = {}
@@ -10124,36 +12446,36 @@ def delete_collection_namespaced_pod_with_http_info(self, namespace, **kwargs):
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -10168,6 +12490,11 @@ def delete_collection_namespaced_pod_with_http_info(self, namespace, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods', 'DELETE',
path_params,
@@ -10176,13 +12503,14 @@ def delete_collection_namespaced_pod_with_http_info(self, namespace, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_namespaced_pod_template(self, namespace, **kwargs): # noqa: E501
"""delete_collection_namespaced_pod_template # noqa: E501
@@ -10190,36 +12518,56 @@ def delete_collection_namespaced_pod_template(self, namespace, **kwargs): # noq
delete collection of PodTemplate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_pod_template(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_namespaced_pod_template_with_http_info(namespace, **kwargs) # noqa: E501
@@ -10230,38 +12578,64 @@ def delete_collection_namespaced_pod_template_with_http_info(self, namespace, **
delete collection of PodTemplate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_pod_template_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -10289,7 +12663,10 @@ def delete_collection_namespaced_pod_template_with_http_info(self, namespace, **
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -10302,8 +12679,7 @@ def delete_collection_namespaced_pod_template_with_http_info(self, namespace, **
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_pod_template`") # noqa: E501
collection_formats = {}
@@ -10313,36 +12689,36 @@ def delete_collection_namespaced_pod_template_with_http_info(self, namespace, **
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -10357,6 +12733,11 @@ def delete_collection_namespaced_pod_template_with_http_info(self, namespace, **
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/podtemplates', 'DELETE',
path_params,
@@ -10365,13 +12746,14 @@ def delete_collection_namespaced_pod_template_with_http_info(self, namespace, **
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_namespaced_replication_controller(self, namespace, **kwargs): # noqa: E501
"""delete_collection_namespaced_replication_controller # noqa: E501
@@ -10379,36 +12761,56 @@ def delete_collection_namespaced_replication_controller(self, namespace, **kwarg
delete collection of ReplicationController # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_replication_controller(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_namespaced_replication_controller_with_http_info(namespace, **kwargs) # noqa: E501
@@ -10419,38 +12821,64 @@ def delete_collection_namespaced_replication_controller_with_http_info(self, nam
delete collection of ReplicationController # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_replication_controller_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -10478,7 +12906,10 @@ def delete_collection_namespaced_replication_controller_with_http_info(self, nam
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -10491,8 +12922,7 @@ def delete_collection_namespaced_replication_controller_with_http_info(self, nam
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_replication_controller`") # noqa: E501
collection_formats = {}
@@ -10502,36 +12932,36 @@ def delete_collection_namespaced_replication_controller_with_http_info(self, nam
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -10546,6 +12976,11 @@ def delete_collection_namespaced_replication_controller_with_http_info(self, nam
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/replicationcontrollers', 'DELETE',
path_params,
@@ -10554,13 +12989,14 @@ def delete_collection_namespaced_replication_controller_with_http_info(self, nam
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_namespaced_resource_quota(self, namespace, **kwargs): # noqa: E501
"""delete_collection_namespaced_resource_quota # noqa: E501
@@ -10568,36 +13004,56 @@ def delete_collection_namespaced_resource_quota(self, namespace, **kwargs): # n
delete collection of ResourceQuota # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_resource_quota(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_namespaced_resource_quota_with_http_info(namespace, **kwargs) # noqa: E501
@@ -10608,38 +13064,64 @@ def delete_collection_namespaced_resource_quota_with_http_info(self, namespace,
delete collection of ResourceQuota # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_resource_quota_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -10667,7 +13149,10 @@ def delete_collection_namespaced_resource_quota_with_http_info(self, namespace,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -10680,8 +13165,7 @@ def delete_collection_namespaced_resource_quota_with_http_info(self, namespace,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_resource_quota`") # noqa: E501
collection_formats = {}
@@ -10691,36 +13175,36 @@ def delete_collection_namespaced_resource_quota_with_http_info(self, namespace,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -10735,6 +13219,11 @@ def delete_collection_namespaced_resource_quota_with_http_info(self, namespace,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/resourcequotas', 'DELETE',
path_params,
@@ -10743,13 +13232,14 @@ def delete_collection_namespaced_resource_quota_with_http_info(self, namespace,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_namespaced_secret(self, namespace, **kwargs): # noqa: E501
"""delete_collection_namespaced_secret # noqa: E501
@@ -10757,36 +13247,56 @@ def delete_collection_namespaced_secret(self, namespace, **kwargs): # noqa: E50
delete collection of Secret # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_secret(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_namespaced_secret_with_http_info(namespace, **kwargs) # noqa: E501
@@ -10797,38 +13307,64 @@ def delete_collection_namespaced_secret_with_http_info(self, namespace, **kwargs
delete collection of Secret # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_secret_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -10856,7 +13392,10 @@ def delete_collection_namespaced_secret_with_http_info(self, namespace, **kwargs
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -10869,8 +13408,7 @@ def delete_collection_namespaced_secret_with_http_info(self, namespace, **kwargs
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_secret`") # noqa: E501
collection_formats = {}
@@ -10880,36 +13418,36 @@ def delete_collection_namespaced_secret_with_http_info(self, namespace, **kwargs
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -10924,6 +13462,11 @@ def delete_collection_namespaced_secret_with_http_info(self, namespace, **kwargs
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/secrets', 'DELETE',
path_params,
@@ -10932,13 +13475,14 @@ def delete_collection_namespaced_secret_with_http_info(self, namespace, **kwargs
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_namespaced_service(self, namespace, **kwargs): # noqa: E501
"""delete_collection_namespaced_service # noqa: E501
@@ -10946,36 +13490,56 @@ def delete_collection_namespaced_service(self, namespace, **kwargs): # noqa: E5
delete collection of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_service(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_namespaced_service_with_http_info(namespace, **kwargs) # noqa: E501
@@ -10986,38 +13550,64 @@ def delete_collection_namespaced_service_with_http_info(self, namespace, **kwarg
delete collection of Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_service_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -11045,7 +13635,10 @@ def delete_collection_namespaced_service_with_http_info(self, namespace, **kwarg
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -11058,8 +13651,7 @@ def delete_collection_namespaced_service_with_http_info(self, namespace, **kwarg
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_service`") # noqa: E501
collection_formats = {}
@@ -11069,36 +13661,36 @@ def delete_collection_namespaced_service_with_http_info(self, namespace, **kwarg
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -11113,6 +13705,11 @@ def delete_collection_namespaced_service_with_http_info(self, namespace, **kwarg
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/services', 'DELETE',
path_params,
@@ -11121,13 +13718,14 @@ def delete_collection_namespaced_service_with_http_info(self, namespace, **kwarg
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_namespaced_service_account(self, namespace, **kwargs): # noqa: E501
"""delete_collection_namespaced_service_account # noqa: E501
@@ -11135,36 +13733,56 @@ def delete_collection_namespaced_service_account(self, namespace, **kwargs): #
delete collection of ServiceAccount # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_service_account(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_namespaced_service_account_with_http_info(namespace, **kwargs) # noqa: E501
@@ -11175,38 +13793,64 @@ def delete_collection_namespaced_service_account_with_http_info(self, namespace,
delete collection of ServiceAccount # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_service_account_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -11234,7 +13878,10 @@ def delete_collection_namespaced_service_account_with_http_info(self, namespace,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -11247,8 +13894,7 @@ def delete_collection_namespaced_service_account_with_http_info(self, namespace,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_service_account`") # noqa: E501
collection_formats = {}
@@ -11258,36 +13904,36 @@ def delete_collection_namespaced_service_account_with_http_info(self, namespace,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -11302,6 +13948,11 @@ def delete_collection_namespaced_service_account_with_http_info(self, namespace,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/serviceaccounts', 'DELETE',
path_params,
@@ -11310,13 +13961,14 @@ def delete_collection_namespaced_service_account_with_http_info(self, namespace,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_node(self, **kwargs): # noqa: E501
"""delete_collection_node # noqa: E501
@@ -11324,35 +13976,54 @@ def delete_collection_node(self, **kwargs): # noqa: E501
delete collection of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_node(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_node_with_http_info(**kwargs) # noqa: E501
@@ -11363,37 +14034,62 @@ def delete_collection_node_with_http_info(self, **kwargs): # noqa: E501
delete collection of Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_node_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -11420,7 +14116,10 @@ def delete_collection_node_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -11438,36 +14137,36 @@ def delete_collection_node_with_http_info(self, **kwargs): # noqa: E501
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -11482,6 +14181,11 @@ def delete_collection_node_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/nodes', 'DELETE',
path_params,
@@ -11490,13 +14194,14 @@ def delete_collection_node_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_persistent_volume(self, **kwargs): # noqa: E501
"""delete_collection_persistent_volume # noqa: E501
@@ -11504,35 +14209,54 @@ def delete_collection_persistent_volume(self, **kwargs): # noqa: E501
delete collection of PersistentVolume # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_persistent_volume(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_persistent_volume_with_http_info(**kwargs) # noqa: E501
@@ -11543,37 +14267,62 @@ def delete_collection_persistent_volume_with_http_info(self, **kwargs): # noqa:
delete collection of PersistentVolume # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_persistent_volume_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -11600,7 +14349,10 @@ def delete_collection_persistent_volume_with_http_info(self, **kwargs): # noqa:
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -11618,36 +14370,36 @@ def delete_collection_persistent_volume_with_http_info(self, **kwargs): # noqa:
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -11662,6 +14414,11 @@ def delete_collection_persistent_volume_with_http_info(self, **kwargs): # noqa:
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/persistentvolumes', 'DELETE',
path_params,
@@ -11670,13 +14427,14 @@ def delete_collection_persistent_volume_with_http_info(self, **kwargs): # noqa:
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_namespace(self, name, **kwargs): # noqa: E501
"""delete_namespace # noqa: E501
@@ -11684,28 +14442,40 @@ def delete_namespace(self, name, **kwargs): # noqa: E501
delete a Namespace # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespace(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Namespace (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the Namespace (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_namespace_with_http_info(name, **kwargs) # noqa: E501
@@ -11716,30 +14486,48 @@ def delete_namespace_with_http_info(self, name, **kwargs): # noqa: E501
delete a Namespace # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespace_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Namespace (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the Namespace (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -11759,7 +14547,10 @@ def delete_namespace_with_http_info(self, name, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -11772,8 +14563,7 @@ def delete_namespace_with_http_info(self, name, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_namespace`") # noqa: E501
collection_formats = {}
@@ -11783,20 +14573,20 @@ def delete_namespace_with_http_info(self, name, **kwargs): # noqa: E501
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -11811,6 +14601,12 @@ def delete_namespace_with_http_info(self, name, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{name}', 'DELETE',
path_params,
@@ -11819,13 +14615,14 @@ def delete_namespace_with_http_info(self, name, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_namespaced_config_map(self, name, namespace, **kwargs): # noqa: E501
"""delete_namespaced_config_map # noqa: E501
@@ -11833,29 +14630,42 @@ def delete_namespaced_config_map(self, name, namespace, **kwargs): # noqa: E501
delete a ConfigMap # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_config_map(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ConfigMap (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the ConfigMap (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_namespaced_config_map_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -11866,31 +14676,50 @@ def delete_namespaced_config_map_with_http_info(self, name, namespace, **kwargs)
delete a ConfigMap # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_config_map_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ConfigMap (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the ConfigMap (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -11911,7 +14740,10 @@ def delete_namespaced_config_map_with_http_info(self, name, namespace, **kwargs)
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -11924,12 +14756,10 @@ def delete_namespaced_config_map_with_http_info(self, name, namespace, **kwargs)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_config_map`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_config_map`") # noqa: E501
collection_formats = {}
@@ -11941,20 +14771,20 @@ def delete_namespaced_config_map_with_http_info(self, name, namespace, **kwargs)
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -11969,6 +14799,12 @@ def delete_namespaced_config_map_with_http_info(self, name, namespace, **kwargs)
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/configmaps/{name}', 'DELETE',
path_params,
@@ -11977,13 +14813,14 @@ def delete_namespaced_config_map_with_http_info(self, name, namespace, **kwargs)
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_namespaced_endpoints(self, name, namespace, **kwargs): # noqa: E501
"""delete_namespaced_endpoints # noqa: E501
@@ -11991,29 +14828,42 @@ def delete_namespaced_endpoints(self, name, namespace, **kwargs): # noqa: E501
delete Endpoints # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_endpoints(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Endpoints (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the Endpoints (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_namespaced_endpoints_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -12024,31 +14874,50 @@ def delete_namespaced_endpoints_with_http_info(self, name, namespace, **kwargs):
delete Endpoints # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_endpoints_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Endpoints (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the Endpoints (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -12069,7 +14938,10 @@ def delete_namespaced_endpoints_with_http_info(self, name, namespace, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -12082,12 +14954,10 @@ def delete_namespaced_endpoints_with_http_info(self, name, namespace, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_endpoints`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_endpoints`") # noqa: E501
collection_formats = {}
@@ -12099,20 +14969,20 @@ def delete_namespaced_endpoints_with_http_info(self, name, namespace, **kwargs):
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -12127,6 +14997,12 @@ def delete_namespaced_endpoints_with_http_info(self, name, namespace, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/endpoints/{name}', 'DELETE',
path_params,
@@ -12135,13 +15011,14 @@ def delete_namespaced_endpoints_with_http_info(self, name, namespace, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_namespaced_event(self, name, namespace, **kwargs): # noqa: E501
"""delete_namespaced_event # noqa: E501
@@ -12149,29 +15026,42 @@ def delete_namespaced_event(self, name, namespace, **kwargs): # noqa: E501
delete an Event # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_event(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Event (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the Event (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_namespaced_event_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -12182,31 +15072,50 @@ def delete_namespaced_event_with_http_info(self, name, namespace, **kwargs): #
delete an Event # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_event_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Event (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the Event (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -12227,7 +15136,10 @@ def delete_namespaced_event_with_http_info(self, name, namespace, **kwargs): #
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -12240,12 +15152,10 @@ def delete_namespaced_event_with_http_info(self, name, namespace, **kwargs): #
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_event`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_event`") # noqa: E501
collection_formats = {}
@@ -12257,20 +15167,20 @@ def delete_namespaced_event_with_http_info(self, name, namespace, **kwargs): #
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -12285,6 +15195,12 @@ def delete_namespaced_event_with_http_info(self, name, namespace, **kwargs): #
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/events/{name}', 'DELETE',
path_params,
@@ -12293,13 +15209,14 @@ def delete_namespaced_event_with_http_info(self, name, namespace, **kwargs): #
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_namespaced_limit_range(self, name, namespace, **kwargs): # noqa: E501
"""delete_namespaced_limit_range # noqa: E501
@@ -12307,29 +15224,42 @@ def delete_namespaced_limit_range(self, name, namespace, **kwargs): # noqa: E50
delete a LimitRange # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_limit_range(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the LimitRange (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the LimitRange (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_namespaced_limit_range_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -12340,31 +15270,50 @@ def delete_namespaced_limit_range_with_http_info(self, name, namespace, **kwargs
delete a LimitRange # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_limit_range_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the LimitRange (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the LimitRange (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -12385,7 +15334,10 @@ def delete_namespaced_limit_range_with_http_info(self, name, namespace, **kwargs
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -12398,12 +15350,10 @@ def delete_namespaced_limit_range_with_http_info(self, name, namespace, **kwargs
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_limit_range`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_limit_range`") # noqa: E501
collection_formats = {}
@@ -12415,20 +15365,20 @@ def delete_namespaced_limit_range_with_http_info(self, name, namespace, **kwargs
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -12443,6 +15393,12 @@ def delete_namespaced_limit_range_with_http_info(self, name, namespace, **kwargs
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/limitranges/{name}', 'DELETE',
path_params,
@@ -12451,13 +15407,14 @@ def delete_namespaced_limit_range_with_http_info(self, name, namespace, **kwargs
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_namespaced_persistent_volume_claim(self, name, namespace, **kwargs): # noqa: E501
"""delete_namespaced_persistent_volume_claim # noqa: E501
@@ -12465,29 +15422,42 @@ def delete_namespaced_persistent_volume_claim(self, name, namespace, **kwargs):
delete a PersistentVolumeClaim # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_persistent_volume_claim(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PersistentVolumeClaim (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the PersistentVolumeClaim (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1PersistentVolumeClaim
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1PersistentVolumeClaim
"""
kwargs['_return_http_data_only'] = True
return self.delete_namespaced_persistent_volume_claim_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -12498,31 +15468,50 @@ def delete_namespaced_persistent_volume_claim_with_http_info(self, name, namespa
delete a PersistentVolumeClaim # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_persistent_volume_claim_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PersistentVolumeClaim (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the PersistentVolumeClaim (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1PersistentVolumeClaim, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1PersistentVolumeClaim, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -12543,7 +15532,10 @@ def delete_namespaced_persistent_volume_claim_with_http_info(self, name, namespa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -12556,12 +15548,10 @@ def delete_namespaced_persistent_volume_claim_with_http_info(self, name, namespa
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_persistent_volume_claim`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_persistent_volume_claim`") # noqa: E501
collection_formats = {}
@@ -12573,20 +15563,20 @@ def delete_namespaced_persistent_volume_claim_with_http_info(self, name, namespa
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -12601,6 +15591,12 @@ def delete_namespaced_persistent_volume_claim_with_http_info(self, name, namespa
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1PersistentVolumeClaim",
+ 202: "V1PersistentVolumeClaim",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/persistentvolumeclaims/{name}', 'DELETE',
path_params,
@@ -12609,13 +15605,14 @@ def delete_namespaced_persistent_volume_claim_with_http_info(self, name, namespa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1PersistentVolumeClaim', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_namespaced_pod(self, name, namespace, **kwargs): # noqa: E501
"""delete_namespaced_pod # noqa: E501
@@ -12623,29 +15620,42 @@ def delete_namespaced_pod(self, name, namespace, **kwargs): # noqa: E501
delete a Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_pod(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Pod (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the Pod (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Pod
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Pod
"""
kwargs['_return_http_data_only'] = True
return self.delete_namespaced_pod_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -12656,31 +15666,50 @@ def delete_namespaced_pod_with_http_info(self, name, namespace, **kwargs): # no
delete a Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_pod_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Pod (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the Pod (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Pod, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Pod, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -12701,7 +15730,10 @@ def delete_namespaced_pod_with_http_info(self, name, namespace, **kwargs): # no
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -12714,12 +15746,10 @@ def delete_namespaced_pod_with_http_info(self, name, namespace, **kwargs): # no
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_pod`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_pod`") # noqa: E501
collection_formats = {}
@@ -12731,20 +15761,20 @@ def delete_namespaced_pod_with_http_info(self, name, namespace, **kwargs): # no
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -12759,6 +15789,12 @@ def delete_namespaced_pod_with_http_info(self, name, namespace, **kwargs): # no
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Pod",
+ 202: "V1Pod",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}', 'DELETE',
path_params,
@@ -12767,13 +15803,14 @@ def delete_namespaced_pod_with_http_info(self, name, namespace, **kwargs): # no
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Pod', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_namespaced_pod_template(self, name, namespace, **kwargs): # noqa: E501
"""delete_namespaced_pod_template # noqa: E501
@@ -12781,29 +15818,42 @@ def delete_namespaced_pod_template(self, name, namespace, **kwargs): # noqa: E5
delete a PodTemplate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_pod_template(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodTemplate (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the PodTemplate (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1PodTemplate
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1PodTemplate
"""
kwargs['_return_http_data_only'] = True
return self.delete_namespaced_pod_template_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -12814,31 +15864,50 @@ def delete_namespaced_pod_template_with_http_info(self, name, namespace, **kwarg
delete a PodTemplate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_pod_template_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodTemplate (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the PodTemplate (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1PodTemplate, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1PodTemplate, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -12859,7 +15928,10 @@ def delete_namespaced_pod_template_with_http_info(self, name, namespace, **kwarg
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -12872,12 +15944,10 @@ def delete_namespaced_pod_template_with_http_info(self, name, namespace, **kwarg
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_pod_template`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_pod_template`") # noqa: E501
collection_formats = {}
@@ -12889,20 +15959,20 @@ def delete_namespaced_pod_template_with_http_info(self, name, namespace, **kwarg
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -12917,6 +15987,12 @@ def delete_namespaced_pod_template_with_http_info(self, name, namespace, **kwarg
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1PodTemplate",
+ 202: "V1PodTemplate",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/podtemplates/{name}', 'DELETE',
path_params,
@@ -12925,13 +16001,14 @@ def delete_namespaced_pod_template_with_http_info(self, name, namespace, **kwarg
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1PodTemplate', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_namespaced_replication_controller(self, name, namespace, **kwargs): # noqa: E501
"""delete_namespaced_replication_controller # noqa: E501
@@ -12939,29 +16016,42 @@ def delete_namespaced_replication_controller(self, name, namespace, **kwargs):
delete a ReplicationController # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_replication_controller(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ReplicationController (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the ReplicationController (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_namespaced_replication_controller_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -12972,31 +16062,50 @@ def delete_namespaced_replication_controller_with_http_info(self, name, namespac
delete a ReplicationController # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_replication_controller_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ReplicationController (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the ReplicationController (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -13017,7 +16126,10 @@ def delete_namespaced_replication_controller_with_http_info(self, name, namespac
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -13030,12 +16142,10 @@ def delete_namespaced_replication_controller_with_http_info(self, name, namespac
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_replication_controller`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_replication_controller`") # noqa: E501
collection_formats = {}
@@ -13047,20 +16157,20 @@ def delete_namespaced_replication_controller_with_http_info(self, name, namespac
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -13075,6 +16185,12 @@ def delete_namespaced_replication_controller_with_http_info(self, name, namespac
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/replicationcontrollers/{name}', 'DELETE',
path_params,
@@ -13083,13 +16199,14 @@ def delete_namespaced_replication_controller_with_http_info(self, name, namespac
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_namespaced_resource_quota(self, name, namespace, **kwargs): # noqa: E501
"""delete_namespaced_resource_quota # noqa: E501
@@ -13097,29 +16214,42 @@ def delete_namespaced_resource_quota(self, name, namespace, **kwargs): # noqa:
delete a ResourceQuota # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_resource_quota(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ResourceQuota (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the ResourceQuota (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ResourceQuota
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ResourceQuota
"""
kwargs['_return_http_data_only'] = True
return self.delete_namespaced_resource_quota_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -13130,31 +16260,50 @@ def delete_namespaced_resource_quota_with_http_info(self, name, namespace, **kwa
delete a ResourceQuota # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_resource_quota_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ResourceQuota (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the ResourceQuota (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ResourceQuota, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ResourceQuota, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -13175,7 +16324,10 @@ def delete_namespaced_resource_quota_with_http_info(self, name, namespace, **kwa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -13188,12 +16340,10 @@ def delete_namespaced_resource_quota_with_http_info(self, name, namespace, **kwa
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_resource_quota`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_resource_quota`") # noqa: E501
collection_formats = {}
@@ -13205,20 +16355,20 @@ def delete_namespaced_resource_quota_with_http_info(self, name, namespace, **kwa
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -13233,6 +16383,12 @@ def delete_namespaced_resource_quota_with_http_info(self, name, namespace, **kwa
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ResourceQuota",
+ 202: "V1ResourceQuota",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/resourcequotas/{name}', 'DELETE',
path_params,
@@ -13241,13 +16397,14 @@ def delete_namespaced_resource_quota_with_http_info(self, name, namespace, **kwa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ResourceQuota', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_namespaced_secret(self, name, namespace, **kwargs): # noqa: E501
"""delete_namespaced_secret # noqa: E501
@@ -13255,29 +16412,42 @@ def delete_namespaced_secret(self, name, namespace, **kwargs): # noqa: E501
delete a Secret # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_secret(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Secret (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the Secret (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_namespaced_secret_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -13288,31 +16458,50 @@ def delete_namespaced_secret_with_http_info(self, name, namespace, **kwargs): #
delete a Secret # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_secret_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Secret (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the Secret (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -13333,7 +16522,10 @@ def delete_namespaced_secret_with_http_info(self, name, namespace, **kwargs): #
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -13346,12 +16538,10 @@ def delete_namespaced_secret_with_http_info(self, name, namespace, **kwargs): #
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_secret`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_secret`") # noqa: E501
collection_formats = {}
@@ -13363,20 +16553,20 @@ def delete_namespaced_secret_with_http_info(self, name, namespace, **kwargs): #
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -13391,6 +16581,12 @@ def delete_namespaced_secret_with_http_info(self, name, namespace, **kwargs): #
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/secrets/{name}', 'DELETE',
path_params,
@@ -13399,13 +16595,14 @@ def delete_namespaced_secret_with_http_info(self, name, namespace, **kwargs): #
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_namespaced_service(self, name, namespace, **kwargs): # noqa: E501
"""delete_namespaced_service # noqa: E501
@@ -13413,29 +16610,42 @@ def delete_namespaced_service(self, name, namespace, **kwargs): # noqa: E501
delete a Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_service(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Service (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the Service (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Service
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Service
"""
kwargs['_return_http_data_only'] = True
return self.delete_namespaced_service_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -13446,31 +16656,50 @@ def delete_namespaced_service_with_http_info(self, name, namespace, **kwargs):
delete a Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_service_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Service (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the Service (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Service, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Service, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -13491,7 +16720,10 @@ def delete_namespaced_service_with_http_info(self, name, namespace, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -13504,12 +16736,10 @@ def delete_namespaced_service_with_http_info(self, name, namespace, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_service`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_service`") # noqa: E501
collection_formats = {}
@@ -13521,20 +16751,20 @@ def delete_namespaced_service_with_http_info(self, name, namespace, **kwargs):
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -13549,6 +16779,12 @@ def delete_namespaced_service_with_http_info(self, name, namespace, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Service",
+ 202: "V1Service",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/services/{name}', 'DELETE',
path_params,
@@ -13557,13 +16793,14 @@ def delete_namespaced_service_with_http_info(self, name, namespace, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Service', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_namespaced_service_account(self, name, namespace, **kwargs): # noqa: E501
"""delete_namespaced_service_account # noqa: E501
@@ -13571,29 +16808,42 @@ def delete_namespaced_service_account(self, name, namespace, **kwargs): # noqa:
delete a ServiceAccount # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_service_account(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceAccount (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the ServiceAccount (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ServiceAccount
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ServiceAccount
"""
kwargs['_return_http_data_only'] = True
return self.delete_namespaced_service_account_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -13604,31 +16854,50 @@ def delete_namespaced_service_account_with_http_info(self, name, namespace, **kw
delete a ServiceAccount # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_service_account_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceAccount (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the ServiceAccount (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ServiceAccount, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ServiceAccount, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -13649,7 +16918,10 @@ def delete_namespaced_service_account_with_http_info(self, name, namespace, **kw
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -13662,12 +16934,10 @@ def delete_namespaced_service_account_with_http_info(self, name, namespace, **kw
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_service_account`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_service_account`") # noqa: E501
collection_formats = {}
@@ -13679,20 +16949,20 @@ def delete_namespaced_service_account_with_http_info(self, name, namespace, **kw
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -13707,6 +16977,12 @@ def delete_namespaced_service_account_with_http_info(self, name, namespace, **kw
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ServiceAccount",
+ 202: "V1ServiceAccount",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/serviceaccounts/{name}', 'DELETE',
path_params,
@@ -13715,13 +16991,14 @@ def delete_namespaced_service_account_with_http_info(self, name, namespace, **kw
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ServiceAccount', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_node(self, name, **kwargs): # noqa: E501
"""delete_node # noqa: E501
@@ -13729,28 +17006,40 @@ def delete_node(self, name, **kwargs): # noqa: E501
delete a Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_node(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Node (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the Node (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_node_with_http_info(name, **kwargs) # noqa: E501
@@ -13761,30 +17050,48 @@ def delete_node_with_http_info(self, name, **kwargs): # noqa: E501
delete a Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_node_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Node (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the Node (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -13804,7 +17111,10 @@ def delete_node_with_http_info(self, name, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -13817,8 +17127,7 @@ def delete_node_with_http_info(self, name, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_node`") # noqa: E501
collection_formats = {}
@@ -13828,20 +17137,20 @@ def delete_node_with_http_info(self, name, **kwargs): # noqa: E501
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -13856,6 +17165,12 @@ def delete_node_with_http_info(self, name, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/nodes/{name}', 'DELETE',
path_params,
@@ -13864,13 +17179,14 @@ def delete_node_with_http_info(self, name, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_persistent_volume(self, name, **kwargs): # noqa: E501
"""delete_persistent_volume # noqa: E501
@@ -13878,28 +17194,40 @@ def delete_persistent_volume(self, name, **kwargs): # noqa: E501
delete a PersistentVolume # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_persistent_volume(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PersistentVolume (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the PersistentVolume (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1PersistentVolume
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1PersistentVolume
"""
kwargs['_return_http_data_only'] = True
return self.delete_persistent_volume_with_http_info(name, **kwargs) # noqa: E501
@@ -13910,30 +17238,48 @@ def delete_persistent_volume_with_http_info(self, name, **kwargs): # noqa: E501
delete a PersistentVolume # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_persistent_volume_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PersistentVolume (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the PersistentVolume (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1PersistentVolume, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1PersistentVolume, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -13953,7 +17299,10 @@ def delete_persistent_volume_with_http_info(self, name, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -13966,8 +17315,7 @@ def delete_persistent_volume_with_http_info(self, name, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_persistent_volume`") # noqa: E501
collection_formats = {}
@@ -13977,20 +17325,20 @@ def delete_persistent_volume_with_http_info(self, name, **kwargs): # noqa: E501
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -14005,6 +17353,12 @@ def delete_persistent_volume_with_http_info(self, name, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1PersistentVolume",
+ 202: "V1PersistentVolume",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/persistentvolumes/{name}', 'DELETE',
path_params,
@@ -14013,13 +17367,14 @@ def delete_persistent_volume_with_http_info(self, name, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1PersistentVolume', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def get_api_resources(self, **kwargs): # noqa: E501
"""get_api_resources # noqa: E501
@@ -14027,20 +17382,24 @@ def get_api_resources(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIResourceList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIResourceList
"""
kwargs['_return_http_data_only'] = True
return self.get_api_resources_with_http_info(**kwargs) # noqa: E501
@@ -14051,22 +17410,32 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -14078,7 +17447,10 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -14097,7 +17469,7 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -14110,6 +17482,11 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIResourceList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/', 'GET',
path_params,
@@ -14118,13 +17495,14 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIResourceList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_component_status(self, **kwargs): # noqa: E501
"""list_component_status # noqa: E501
@@ -14132,31 +17510,46 @@ def list_component_status(self, **kwargs): # noqa: E501
list objects of kind ComponentStatus # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_component_status(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ComponentStatusList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ComponentStatusList
"""
kwargs['_return_http_data_only'] = True
return self.list_component_status_with_http_info(**kwargs) # noqa: E501
@@ -14167,33 +17560,54 @@ def list_component_status_with_http_info(self, **kwargs): # noqa: E501
list objects of kind ComponentStatus # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_component_status_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ComponentStatusList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ComponentStatusList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -14216,7 +17630,10 @@ def list_component_status_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -14234,30 +17651,30 @@ def list_component_status_with_http_info(self, **kwargs): # noqa: E501
path_params = {}
query_params = []
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -14270,6 +17687,11 @@ def list_component_status_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ComponentStatusList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/componentstatuses', 'GET',
path_params,
@@ -14278,13 +17700,14 @@ def list_component_status_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ComponentStatusList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_config_map_for_all_namespaces(self, **kwargs): # noqa: E501
"""list_config_map_for_all_namespaces # noqa: E501
@@ -14292,31 +17715,46 @@ def list_config_map_for_all_namespaces(self, **kwargs): # noqa: E501
list or watch objects of kind ConfigMap # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_config_map_for_all_namespaces(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ConfigMapList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ConfigMapList
"""
kwargs['_return_http_data_only'] = True
return self.list_config_map_for_all_namespaces_with_http_info(**kwargs) # noqa: E501
@@ -14327,33 +17765,54 @@ def list_config_map_for_all_namespaces_with_http_info(self, **kwargs): # noqa:
list or watch objects of kind ConfigMap # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_config_map_for_all_namespaces_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ConfigMapList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ConfigMapList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -14376,7 +17835,10 @@ def list_config_map_for_all_namespaces_with_http_info(self, **kwargs): # noqa:
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -14394,30 +17856,30 @@ def list_config_map_for_all_namespaces_with_http_info(self, **kwargs): # noqa:
path_params = {}
query_params = []
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -14430,6 +17892,11 @@ def list_config_map_for_all_namespaces_with_http_info(self, **kwargs): # noqa:
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ConfigMapList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/configmaps', 'GET',
path_params,
@@ -14438,13 +17905,14 @@ def list_config_map_for_all_namespaces_with_http_info(self, **kwargs): # noqa:
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ConfigMapList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_endpoints_for_all_namespaces(self, **kwargs): # noqa: E501
"""list_endpoints_for_all_namespaces # noqa: E501
@@ -14452,31 +17920,46 @@ def list_endpoints_for_all_namespaces(self, **kwargs): # noqa: E501
list or watch objects of kind Endpoints # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_endpoints_for_all_namespaces(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1EndpointsList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1EndpointsList
"""
kwargs['_return_http_data_only'] = True
return self.list_endpoints_for_all_namespaces_with_http_info(**kwargs) # noqa: E501
@@ -14487,33 +17970,54 @@ def list_endpoints_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E
list or watch objects of kind Endpoints # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_endpoints_for_all_namespaces_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1EndpointsList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1EndpointsList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -14536,7 +18040,10 @@ def list_endpoints_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -14554,30 +18061,30 @@ def list_endpoints_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E
path_params = {}
query_params = []
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -14590,6 +18097,11 @@ def list_endpoints_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1EndpointsList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/endpoints', 'GET',
path_params,
@@ -14598,13 +18110,14 @@ def list_endpoints_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1EndpointsList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_event_for_all_namespaces(self, **kwargs): # noqa: E501
"""list_event_for_all_namespaces # noqa: E501
@@ -14612,31 +18125,46 @@ def list_event_for_all_namespaces(self, **kwargs): # noqa: E501
list or watch objects of kind Event # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_event_for_all_namespaces(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: CoreV1EventList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: CoreV1EventList
"""
kwargs['_return_http_data_only'] = True
return self.list_event_for_all_namespaces_with_http_info(**kwargs) # noqa: E501
@@ -14647,33 +18175,54 @@ def list_event_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501
list or watch objects of kind Event # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_event_for_all_namespaces_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(CoreV1EventList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(CoreV1EventList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -14696,7 +18245,10 @@ def list_event_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -14714,30 +18266,30 @@ def list_event_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501
path_params = {}
query_params = []
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -14750,6 +18302,11 @@ def list_event_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "CoreV1EventList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/events', 'GET',
path_params,
@@ -14758,13 +18315,14 @@ def list_event_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='CoreV1EventList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_limit_range_for_all_namespaces(self, **kwargs): # noqa: E501
"""list_limit_range_for_all_namespaces # noqa: E501
@@ -14772,31 +18330,46 @@ def list_limit_range_for_all_namespaces(self, **kwargs): # noqa: E501
list or watch objects of kind LimitRange # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_limit_range_for_all_namespaces(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1LimitRangeList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1LimitRangeList
"""
kwargs['_return_http_data_only'] = True
return self.list_limit_range_for_all_namespaces_with_http_info(**kwargs) # noqa: E501
@@ -14807,33 +18380,54 @@ def list_limit_range_for_all_namespaces_with_http_info(self, **kwargs): # noqa:
list or watch objects of kind LimitRange # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_limit_range_for_all_namespaces_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1LimitRangeList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1LimitRangeList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -14856,7 +18450,10 @@ def list_limit_range_for_all_namespaces_with_http_info(self, **kwargs): # noqa:
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -14874,30 +18471,30 @@ def list_limit_range_for_all_namespaces_with_http_info(self, **kwargs): # noqa:
path_params = {}
query_params = []
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -14910,6 +18507,11 @@ def list_limit_range_for_all_namespaces_with_http_info(self, **kwargs): # noqa:
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1LimitRangeList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/limitranges', 'GET',
path_params,
@@ -14918,13 +18520,14 @@ def list_limit_range_for_all_namespaces_with_http_info(self, **kwargs): # noqa:
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1LimitRangeList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_namespace(self, **kwargs): # noqa: E501
"""list_namespace # noqa: E501
@@ -14932,31 +18535,46 @@ def list_namespace(self, **kwargs): # noqa: E501
list or watch objects of kind Namespace # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespace(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1NamespaceList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1NamespaceList
"""
kwargs['_return_http_data_only'] = True
return self.list_namespace_with_http_info(**kwargs) # noqa: E501
@@ -14967,33 +18585,54 @@ def list_namespace_with_http_info(self, **kwargs): # noqa: E501
list or watch objects of kind Namespace # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespace_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1NamespaceList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1NamespaceList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -15016,7 +18655,10 @@ def list_namespace_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -15034,30 +18676,30 @@ def list_namespace_with_http_info(self, **kwargs): # noqa: E501
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -15070,6 +18712,11 @@ def list_namespace_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1NamespaceList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces', 'GET',
path_params,
@@ -15078,13 +18725,14 @@ def list_namespace_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1NamespaceList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_namespaced_config_map(self, namespace, **kwargs): # noqa: E501
"""list_namespaced_config_map # noqa: E501
@@ -15092,32 +18740,48 @@ def list_namespaced_config_map(self, namespace, **kwargs): # noqa: E501
list or watch objects of kind ConfigMap # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_config_map(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ConfigMapList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ConfigMapList
"""
kwargs['_return_http_data_only'] = True
return self.list_namespaced_config_map_with_http_info(namespace, **kwargs) # noqa: E501
@@ -15128,34 +18792,56 @@ def list_namespaced_config_map_with_http_info(self, namespace, **kwargs): # noq
list or watch objects of kind ConfigMap # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_config_map_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ConfigMapList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ConfigMapList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -15179,7 +18865,10 @@ def list_namespaced_config_map_with_http_info(self, namespace, **kwargs): # noq
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -15192,8 +18881,7 @@ def list_namespaced_config_map_with_http_info(self, namespace, **kwargs): # noq
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_config_map`") # noqa: E501
collection_formats = {}
@@ -15203,30 +18891,30 @@ def list_namespaced_config_map_with_http_info(self, namespace, **kwargs): # noq
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -15239,6 +18927,11 @@ def list_namespaced_config_map_with_http_info(self, namespace, **kwargs): # noq
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ConfigMapList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/configmaps', 'GET',
path_params,
@@ -15247,13 +18940,14 @@ def list_namespaced_config_map_with_http_info(self, namespace, **kwargs): # noq
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ConfigMapList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_namespaced_endpoints(self, namespace, **kwargs): # noqa: E501
"""list_namespaced_endpoints # noqa: E501
@@ -15261,32 +18955,48 @@ def list_namespaced_endpoints(self, namespace, **kwargs): # noqa: E501
list or watch objects of kind Endpoints # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_endpoints(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1EndpointsList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1EndpointsList
"""
kwargs['_return_http_data_only'] = True
return self.list_namespaced_endpoints_with_http_info(namespace, **kwargs) # noqa: E501
@@ -15297,34 +19007,56 @@ def list_namespaced_endpoints_with_http_info(self, namespace, **kwargs): # noqa
list or watch objects of kind Endpoints # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_endpoints_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1EndpointsList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1EndpointsList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -15348,7 +19080,10 @@ def list_namespaced_endpoints_with_http_info(self, namespace, **kwargs): # noqa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -15361,8 +19096,7 @@ def list_namespaced_endpoints_with_http_info(self, namespace, **kwargs): # noqa
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_endpoints`") # noqa: E501
collection_formats = {}
@@ -15372,30 +19106,30 @@ def list_namespaced_endpoints_with_http_info(self, namespace, **kwargs): # noqa
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -15408,6 +19142,11 @@ def list_namespaced_endpoints_with_http_info(self, namespace, **kwargs): # noqa
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1EndpointsList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/endpoints', 'GET',
path_params,
@@ -15416,13 +19155,14 @@ def list_namespaced_endpoints_with_http_info(self, namespace, **kwargs): # noqa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1EndpointsList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_namespaced_event(self, namespace, **kwargs): # noqa: E501
"""list_namespaced_event # noqa: E501
@@ -15430,32 +19170,48 @@ def list_namespaced_event(self, namespace, **kwargs): # noqa: E501
list or watch objects of kind Event # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_event(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: CoreV1EventList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: CoreV1EventList
"""
kwargs['_return_http_data_only'] = True
return self.list_namespaced_event_with_http_info(namespace, **kwargs) # noqa: E501
@@ -15466,34 +19222,56 @@ def list_namespaced_event_with_http_info(self, namespace, **kwargs): # noqa: E5
list or watch objects of kind Event # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_event_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(CoreV1EventList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(CoreV1EventList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -15517,7 +19295,10 @@ def list_namespaced_event_with_http_info(self, namespace, **kwargs): # noqa: E5
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -15530,8 +19311,7 @@ def list_namespaced_event_with_http_info(self, namespace, **kwargs): # noqa: E5
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_event`") # noqa: E501
collection_formats = {}
@@ -15541,30 +19321,30 @@ def list_namespaced_event_with_http_info(self, namespace, **kwargs): # noqa: E5
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -15577,6 +19357,11 @@ def list_namespaced_event_with_http_info(self, namespace, **kwargs): # noqa: E5
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "CoreV1EventList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/events', 'GET',
path_params,
@@ -15585,13 +19370,14 @@ def list_namespaced_event_with_http_info(self, namespace, **kwargs): # noqa: E5
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='CoreV1EventList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_namespaced_limit_range(self, namespace, **kwargs): # noqa: E501
"""list_namespaced_limit_range # noqa: E501
@@ -15599,32 +19385,48 @@ def list_namespaced_limit_range(self, namespace, **kwargs): # noqa: E501
list or watch objects of kind LimitRange # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_limit_range(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1LimitRangeList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1LimitRangeList
"""
kwargs['_return_http_data_only'] = True
return self.list_namespaced_limit_range_with_http_info(namespace, **kwargs) # noqa: E501
@@ -15635,34 +19437,56 @@ def list_namespaced_limit_range_with_http_info(self, namespace, **kwargs): # no
list or watch objects of kind LimitRange # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_limit_range_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1LimitRangeList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1LimitRangeList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -15686,7 +19510,10 @@ def list_namespaced_limit_range_with_http_info(self, namespace, **kwargs): # no
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -15699,8 +19526,7 @@ def list_namespaced_limit_range_with_http_info(self, namespace, **kwargs): # no
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_limit_range`") # noqa: E501
collection_formats = {}
@@ -15710,30 +19536,30 @@ def list_namespaced_limit_range_with_http_info(self, namespace, **kwargs): # no
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -15746,6 +19572,11 @@ def list_namespaced_limit_range_with_http_info(self, namespace, **kwargs): # no
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1LimitRangeList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/limitranges', 'GET',
path_params,
@@ -15754,13 +19585,14 @@ def list_namespaced_limit_range_with_http_info(self, namespace, **kwargs): # no
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1LimitRangeList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_namespaced_persistent_volume_claim(self, namespace, **kwargs): # noqa: E501
"""list_namespaced_persistent_volume_claim # noqa: E501
@@ -15768,32 +19600,48 @@ def list_namespaced_persistent_volume_claim(self, namespace, **kwargs): # noqa:
list or watch objects of kind PersistentVolumeClaim # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_persistent_volume_claim(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1PersistentVolumeClaimList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1PersistentVolumeClaimList
"""
kwargs['_return_http_data_only'] = True
return self.list_namespaced_persistent_volume_claim_with_http_info(namespace, **kwargs) # noqa: E501
@@ -15804,34 +19652,56 @@ def list_namespaced_persistent_volume_claim_with_http_info(self, namespace, **kw
list or watch objects of kind PersistentVolumeClaim # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_persistent_volume_claim_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1PersistentVolumeClaimList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1PersistentVolumeClaimList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -15855,7 +19725,10 @@ def list_namespaced_persistent_volume_claim_with_http_info(self, namespace, **kw
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -15868,8 +19741,7 @@ def list_namespaced_persistent_volume_claim_with_http_info(self, namespace, **kw
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_persistent_volume_claim`") # noqa: E501
collection_formats = {}
@@ -15879,30 +19751,30 @@ def list_namespaced_persistent_volume_claim_with_http_info(self, namespace, **kw
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -15915,6 +19787,11 @@ def list_namespaced_persistent_volume_claim_with_http_info(self, namespace, **kw
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1PersistentVolumeClaimList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/persistentvolumeclaims', 'GET',
path_params,
@@ -15923,13 +19800,14 @@ def list_namespaced_persistent_volume_claim_with_http_info(self, namespace, **kw
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1PersistentVolumeClaimList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_namespaced_pod(self, namespace, **kwargs): # noqa: E501
"""list_namespaced_pod # noqa: E501
@@ -15937,32 +19815,48 @@ def list_namespaced_pod(self, namespace, **kwargs): # noqa: E501
list or watch objects of kind Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_pod(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1PodList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1PodList
"""
kwargs['_return_http_data_only'] = True
return self.list_namespaced_pod_with_http_info(namespace, **kwargs) # noqa: E501
@@ -15973,34 +19867,56 @@ def list_namespaced_pod_with_http_info(self, namespace, **kwargs): # noqa: E501
list or watch objects of kind Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_pod_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1PodList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1PodList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -16024,7 +19940,10 @@ def list_namespaced_pod_with_http_info(self, namespace, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -16037,8 +19956,7 @@ def list_namespaced_pod_with_http_info(self, namespace, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_pod`") # noqa: E501
collection_formats = {}
@@ -16048,30 +19966,30 @@ def list_namespaced_pod_with_http_info(self, namespace, **kwargs): # noqa: E501
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -16084,6 +20002,11 @@ def list_namespaced_pod_with_http_info(self, namespace, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1PodList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods', 'GET',
path_params,
@@ -16092,13 +20015,14 @@ def list_namespaced_pod_with_http_info(self, namespace, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1PodList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_namespaced_pod_template(self, namespace, **kwargs): # noqa: E501
"""list_namespaced_pod_template # noqa: E501
@@ -16106,32 +20030,48 @@ def list_namespaced_pod_template(self, namespace, **kwargs): # noqa: E501
list or watch objects of kind PodTemplate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_pod_template(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1PodTemplateList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1PodTemplateList
"""
kwargs['_return_http_data_only'] = True
return self.list_namespaced_pod_template_with_http_info(namespace, **kwargs) # noqa: E501
@@ -16142,34 +20082,56 @@ def list_namespaced_pod_template_with_http_info(self, namespace, **kwargs): # n
list or watch objects of kind PodTemplate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_pod_template_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1PodTemplateList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1PodTemplateList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -16193,7 +20155,10 @@ def list_namespaced_pod_template_with_http_info(self, namespace, **kwargs): # n
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -16206,8 +20171,7 @@ def list_namespaced_pod_template_with_http_info(self, namespace, **kwargs): # n
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_pod_template`") # noqa: E501
collection_formats = {}
@@ -16217,30 +20181,30 @@ def list_namespaced_pod_template_with_http_info(self, namespace, **kwargs): # n
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -16253,6 +20217,11 @@ def list_namespaced_pod_template_with_http_info(self, namespace, **kwargs): # n
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1PodTemplateList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/podtemplates', 'GET',
path_params,
@@ -16261,13 +20230,14 @@ def list_namespaced_pod_template_with_http_info(self, namespace, **kwargs): # n
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1PodTemplateList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_namespaced_replication_controller(self, namespace, **kwargs): # noqa: E501
"""list_namespaced_replication_controller # noqa: E501
@@ -16275,32 +20245,48 @@ def list_namespaced_replication_controller(self, namespace, **kwargs): # noqa:
list or watch objects of kind ReplicationController # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_replication_controller(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ReplicationControllerList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ReplicationControllerList
"""
kwargs['_return_http_data_only'] = True
return self.list_namespaced_replication_controller_with_http_info(namespace, **kwargs) # noqa: E501
@@ -16311,34 +20297,56 @@ def list_namespaced_replication_controller_with_http_info(self, namespace, **kwa
list or watch objects of kind ReplicationController # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_replication_controller_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ReplicationControllerList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ReplicationControllerList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -16362,7 +20370,10 @@ def list_namespaced_replication_controller_with_http_info(self, namespace, **kwa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -16375,8 +20386,7 @@ def list_namespaced_replication_controller_with_http_info(self, namespace, **kwa
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_replication_controller`") # noqa: E501
collection_formats = {}
@@ -16386,30 +20396,30 @@ def list_namespaced_replication_controller_with_http_info(self, namespace, **kwa
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -16422,6 +20432,11 @@ def list_namespaced_replication_controller_with_http_info(self, namespace, **kwa
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ReplicationControllerList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/replicationcontrollers', 'GET',
path_params,
@@ -16430,13 +20445,14 @@ def list_namespaced_replication_controller_with_http_info(self, namespace, **kwa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ReplicationControllerList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_namespaced_resource_quota(self, namespace, **kwargs): # noqa: E501
"""list_namespaced_resource_quota # noqa: E501
@@ -16444,32 +20460,48 @@ def list_namespaced_resource_quota(self, namespace, **kwargs): # noqa: E501
list or watch objects of kind ResourceQuota # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_resource_quota(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ResourceQuotaList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ResourceQuotaList
"""
kwargs['_return_http_data_only'] = True
return self.list_namespaced_resource_quota_with_http_info(namespace, **kwargs) # noqa: E501
@@ -16480,34 +20512,56 @@ def list_namespaced_resource_quota_with_http_info(self, namespace, **kwargs): #
list or watch objects of kind ResourceQuota # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_resource_quota_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ResourceQuotaList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ResourceQuotaList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -16531,7 +20585,10 @@ def list_namespaced_resource_quota_with_http_info(self, namespace, **kwargs): #
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -16544,8 +20601,7 @@ def list_namespaced_resource_quota_with_http_info(self, namespace, **kwargs): #
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_resource_quota`") # noqa: E501
collection_formats = {}
@@ -16555,30 +20611,30 @@ def list_namespaced_resource_quota_with_http_info(self, namespace, **kwargs): #
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -16591,6 +20647,11 @@ def list_namespaced_resource_quota_with_http_info(self, namespace, **kwargs): #
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ResourceQuotaList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/resourcequotas', 'GET',
path_params,
@@ -16599,13 +20660,14 @@ def list_namespaced_resource_quota_with_http_info(self, namespace, **kwargs): #
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ResourceQuotaList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_namespaced_secret(self, namespace, **kwargs): # noqa: E501
"""list_namespaced_secret # noqa: E501
@@ -16613,32 +20675,48 @@ def list_namespaced_secret(self, namespace, **kwargs): # noqa: E501
list or watch objects of kind Secret # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_secret(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1SecretList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1SecretList
"""
kwargs['_return_http_data_only'] = True
return self.list_namespaced_secret_with_http_info(namespace, **kwargs) # noqa: E501
@@ -16649,34 +20727,56 @@ def list_namespaced_secret_with_http_info(self, namespace, **kwargs): # noqa: E
list or watch objects of kind Secret # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_secret_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1SecretList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1SecretList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -16700,7 +20800,10 @@ def list_namespaced_secret_with_http_info(self, namespace, **kwargs): # noqa: E
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -16713,8 +20816,7 @@ def list_namespaced_secret_with_http_info(self, namespace, **kwargs): # noqa: E
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_secret`") # noqa: E501
collection_formats = {}
@@ -16724,30 +20826,30 @@ def list_namespaced_secret_with_http_info(self, namespace, **kwargs): # noqa: E
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -16760,6 +20862,11 @@ def list_namespaced_secret_with_http_info(self, namespace, **kwargs): # noqa: E
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1SecretList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/secrets', 'GET',
path_params,
@@ -16768,13 +20875,14 @@ def list_namespaced_secret_with_http_info(self, namespace, **kwargs): # noqa: E
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1SecretList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_namespaced_service(self, namespace, **kwargs): # noqa: E501
"""list_namespaced_service # noqa: E501
@@ -16782,32 +20890,48 @@ def list_namespaced_service(self, namespace, **kwargs): # noqa: E501
list or watch objects of kind Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_service(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ServiceList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ServiceList
"""
kwargs['_return_http_data_only'] = True
return self.list_namespaced_service_with_http_info(namespace, **kwargs) # noqa: E501
@@ -16818,34 +20942,56 @@ def list_namespaced_service_with_http_info(self, namespace, **kwargs): # noqa:
list or watch objects of kind Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_service_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ServiceList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ServiceList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -16869,7 +21015,10 @@ def list_namespaced_service_with_http_info(self, namespace, **kwargs): # noqa:
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -16882,8 +21031,7 @@ def list_namespaced_service_with_http_info(self, namespace, **kwargs): # noqa:
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_service`") # noqa: E501
collection_formats = {}
@@ -16893,30 +21041,30 @@ def list_namespaced_service_with_http_info(self, namespace, **kwargs): # noqa:
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -16929,6 +21077,11 @@ def list_namespaced_service_with_http_info(self, namespace, **kwargs): # noqa:
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ServiceList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/services', 'GET',
path_params,
@@ -16937,13 +21090,14 @@ def list_namespaced_service_with_http_info(self, namespace, **kwargs): # noqa:
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ServiceList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_namespaced_service_account(self, namespace, **kwargs): # noqa: E501
"""list_namespaced_service_account # noqa: E501
@@ -16951,32 +21105,48 @@ def list_namespaced_service_account(self, namespace, **kwargs): # noqa: E501
list or watch objects of kind ServiceAccount # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_service_account(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ServiceAccountList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ServiceAccountList
"""
kwargs['_return_http_data_only'] = True
return self.list_namespaced_service_account_with_http_info(namespace, **kwargs) # noqa: E501
@@ -16987,34 +21157,56 @@ def list_namespaced_service_account_with_http_info(self, namespace, **kwargs):
list or watch objects of kind ServiceAccount # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_service_account_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ServiceAccountList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ServiceAccountList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -17038,7 +21230,10 @@ def list_namespaced_service_account_with_http_info(self, namespace, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -17051,8 +21246,7 @@ def list_namespaced_service_account_with_http_info(self, namespace, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_service_account`") # noqa: E501
collection_formats = {}
@@ -17062,30 +21256,30 @@ def list_namespaced_service_account_with_http_info(self, namespace, **kwargs):
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -17098,6 +21292,11 @@ def list_namespaced_service_account_with_http_info(self, namespace, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ServiceAccountList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/serviceaccounts', 'GET',
path_params,
@@ -17106,13 +21305,14 @@ def list_namespaced_service_account_with_http_info(self, namespace, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ServiceAccountList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_node(self, **kwargs): # noqa: E501
"""list_node # noqa: E501
@@ -17120,31 +21320,46 @@ def list_node(self, **kwargs): # noqa: E501
list or watch objects of kind Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_node(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1NodeList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1NodeList
"""
kwargs['_return_http_data_only'] = True
return self.list_node_with_http_info(**kwargs) # noqa: E501
@@ -17155,33 +21370,54 @@ def list_node_with_http_info(self, **kwargs): # noqa: E501
list or watch objects of kind Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_node_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1NodeList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1NodeList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -17204,7 +21440,10 @@ def list_node_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -17222,30 +21461,30 @@ def list_node_with_http_info(self, **kwargs): # noqa: E501
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -17258,6 +21497,11 @@ def list_node_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1NodeList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/nodes', 'GET',
path_params,
@@ -17266,13 +21510,14 @@ def list_node_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1NodeList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_persistent_volume(self, **kwargs): # noqa: E501
"""list_persistent_volume # noqa: E501
@@ -17280,31 +21525,46 @@ def list_persistent_volume(self, **kwargs): # noqa: E501
list or watch objects of kind PersistentVolume # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_persistent_volume(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1PersistentVolumeList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1PersistentVolumeList
"""
kwargs['_return_http_data_only'] = True
return self.list_persistent_volume_with_http_info(**kwargs) # noqa: E501
@@ -17315,33 +21575,54 @@ def list_persistent_volume_with_http_info(self, **kwargs): # noqa: E501
list or watch objects of kind PersistentVolume # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_persistent_volume_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1PersistentVolumeList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1PersistentVolumeList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -17364,7 +21645,10 @@ def list_persistent_volume_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -17382,30 +21666,30 @@ def list_persistent_volume_with_http_info(self, **kwargs): # noqa: E501
path_params = {}
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -17418,6 +21702,11 @@ def list_persistent_volume_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1PersistentVolumeList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/persistentvolumes', 'GET',
path_params,
@@ -17426,13 +21715,14 @@ def list_persistent_volume_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1PersistentVolumeList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_persistent_volume_claim_for_all_namespaces(self, **kwargs): # noqa: E501
"""list_persistent_volume_claim_for_all_namespaces # noqa: E501
@@ -17440,31 +21730,46 @@ def list_persistent_volume_claim_for_all_namespaces(self, **kwargs): # noqa: E5
list or watch objects of kind PersistentVolumeClaim # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_persistent_volume_claim_for_all_namespaces(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1PersistentVolumeClaimList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1PersistentVolumeClaimList
"""
kwargs['_return_http_data_only'] = True
return self.list_persistent_volume_claim_for_all_namespaces_with_http_info(**kwargs) # noqa: E501
@@ -17475,33 +21780,54 @@ def list_persistent_volume_claim_for_all_namespaces_with_http_info(self, **kwarg
list or watch objects of kind PersistentVolumeClaim # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_persistent_volume_claim_for_all_namespaces_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1PersistentVolumeClaimList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1PersistentVolumeClaimList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -17524,7 +21850,10 @@ def list_persistent_volume_claim_for_all_namespaces_with_http_info(self, **kwarg
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -17542,30 +21871,30 @@ def list_persistent_volume_claim_for_all_namespaces_with_http_info(self, **kwarg
path_params = {}
query_params = []
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -17578,6 +21907,11 @@ def list_persistent_volume_claim_for_all_namespaces_with_http_info(self, **kwarg
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1PersistentVolumeClaimList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/persistentvolumeclaims', 'GET',
path_params,
@@ -17586,13 +21920,14 @@ def list_persistent_volume_claim_for_all_namespaces_with_http_info(self, **kwarg
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1PersistentVolumeClaimList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_pod_for_all_namespaces(self, **kwargs): # noqa: E501
"""list_pod_for_all_namespaces # noqa: E501
@@ -17600,31 +21935,46 @@ def list_pod_for_all_namespaces(self, **kwargs): # noqa: E501
list or watch objects of kind Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_pod_for_all_namespaces(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1PodList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1PodList
"""
kwargs['_return_http_data_only'] = True
return self.list_pod_for_all_namespaces_with_http_info(**kwargs) # noqa: E501
@@ -17635,33 +21985,54 @@ def list_pod_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501
list or watch objects of kind Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_pod_for_all_namespaces_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1PodList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1PodList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -17684,7 +22055,10 @@ def list_pod_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -17702,30 +22076,30 @@ def list_pod_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501
path_params = {}
query_params = []
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -17738,6 +22112,11 @@ def list_pod_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1PodList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/pods', 'GET',
path_params,
@@ -17746,13 +22125,14 @@ def list_pod_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1PodList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_pod_template_for_all_namespaces(self, **kwargs): # noqa: E501
"""list_pod_template_for_all_namespaces # noqa: E501
@@ -17760,31 +22140,46 @@ def list_pod_template_for_all_namespaces(self, **kwargs): # noqa: E501
list or watch objects of kind PodTemplate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_pod_template_for_all_namespaces(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1PodTemplateList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1PodTemplateList
"""
kwargs['_return_http_data_only'] = True
return self.list_pod_template_for_all_namespaces_with_http_info(**kwargs) # noqa: E501
@@ -17795,33 +22190,54 @@ def list_pod_template_for_all_namespaces_with_http_info(self, **kwargs): # noqa
list or watch objects of kind PodTemplate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_pod_template_for_all_namespaces_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1PodTemplateList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1PodTemplateList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -17844,7 +22260,10 @@ def list_pod_template_for_all_namespaces_with_http_info(self, **kwargs): # noqa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -17862,30 +22281,30 @@ def list_pod_template_for_all_namespaces_with_http_info(self, **kwargs): # noqa
path_params = {}
query_params = []
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -17898,6 +22317,11 @@ def list_pod_template_for_all_namespaces_with_http_info(self, **kwargs): # noqa
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1PodTemplateList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/podtemplates', 'GET',
path_params,
@@ -17906,13 +22330,14 @@ def list_pod_template_for_all_namespaces_with_http_info(self, **kwargs): # noqa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1PodTemplateList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_replication_controller_for_all_namespaces(self, **kwargs): # noqa: E501
"""list_replication_controller_for_all_namespaces # noqa: E501
@@ -17920,31 +22345,46 @@ def list_replication_controller_for_all_namespaces(self, **kwargs): # noqa: E50
list or watch objects of kind ReplicationController # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_replication_controller_for_all_namespaces(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ReplicationControllerList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ReplicationControllerList
"""
kwargs['_return_http_data_only'] = True
return self.list_replication_controller_for_all_namespaces_with_http_info(**kwargs) # noqa: E501
@@ -17955,33 +22395,54 @@ def list_replication_controller_for_all_namespaces_with_http_info(self, **kwargs
list or watch objects of kind ReplicationController # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_replication_controller_for_all_namespaces_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ReplicationControllerList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ReplicationControllerList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -18004,7 +22465,10 @@ def list_replication_controller_for_all_namespaces_with_http_info(self, **kwargs
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -18022,30 +22486,30 @@ def list_replication_controller_for_all_namespaces_with_http_info(self, **kwargs
path_params = {}
query_params = []
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -18058,6 +22522,11 @@ def list_replication_controller_for_all_namespaces_with_http_info(self, **kwargs
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ReplicationControllerList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/replicationcontrollers', 'GET',
path_params,
@@ -18066,13 +22535,14 @@ def list_replication_controller_for_all_namespaces_with_http_info(self, **kwargs
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ReplicationControllerList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_resource_quota_for_all_namespaces(self, **kwargs): # noqa: E501
"""list_resource_quota_for_all_namespaces # noqa: E501
@@ -18080,31 +22550,46 @@ def list_resource_quota_for_all_namespaces(self, **kwargs): # noqa: E501
list or watch objects of kind ResourceQuota # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_resource_quota_for_all_namespaces(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ResourceQuotaList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ResourceQuotaList
"""
kwargs['_return_http_data_only'] = True
return self.list_resource_quota_for_all_namespaces_with_http_info(**kwargs) # noqa: E501
@@ -18115,33 +22600,54 @@ def list_resource_quota_for_all_namespaces_with_http_info(self, **kwargs): # no
list or watch objects of kind ResourceQuota # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_resource_quota_for_all_namespaces_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ResourceQuotaList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ResourceQuotaList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -18164,7 +22670,10 @@ def list_resource_quota_for_all_namespaces_with_http_info(self, **kwargs): # no
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -18182,30 +22691,30 @@ def list_resource_quota_for_all_namespaces_with_http_info(self, **kwargs): # no
path_params = {}
query_params = []
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -18218,6 +22727,11 @@ def list_resource_quota_for_all_namespaces_with_http_info(self, **kwargs): # no
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ResourceQuotaList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/resourcequotas', 'GET',
path_params,
@@ -18226,13 +22740,14 @@ def list_resource_quota_for_all_namespaces_with_http_info(self, **kwargs): # no
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ResourceQuotaList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_secret_for_all_namespaces(self, **kwargs): # noqa: E501
"""list_secret_for_all_namespaces # noqa: E501
@@ -18240,31 +22755,46 @@ def list_secret_for_all_namespaces(self, **kwargs): # noqa: E501
list or watch objects of kind Secret # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_secret_for_all_namespaces(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1SecretList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1SecretList
"""
kwargs['_return_http_data_only'] = True
return self.list_secret_for_all_namespaces_with_http_info(**kwargs) # noqa: E501
@@ -18275,33 +22805,54 @@ def list_secret_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501
list or watch objects of kind Secret # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_secret_for_all_namespaces_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1SecretList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1SecretList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -18324,7 +22875,10 @@ def list_secret_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -18342,30 +22896,30 @@ def list_secret_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501
path_params = {}
query_params = []
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -18378,6 +22932,11 @@ def list_secret_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1SecretList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/secrets', 'GET',
path_params,
@@ -18386,13 +22945,14 @@ def list_secret_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1SecretList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_service_account_for_all_namespaces(self, **kwargs): # noqa: E501
"""list_service_account_for_all_namespaces # noqa: E501
@@ -18400,31 +22960,46 @@ def list_service_account_for_all_namespaces(self, **kwargs): # noqa: E501
list or watch objects of kind ServiceAccount # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_service_account_for_all_namespaces(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ServiceAccountList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ServiceAccountList
"""
kwargs['_return_http_data_only'] = True
return self.list_service_account_for_all_namespaces_with_http_info(**kwargs) # noqa: E501
@@ -18435,33 +23010,54 @@ def list_service_account_for_all_namespaces_with_http_info(self, **kwargs): # n
list or watch objects of kind ServiceAccount # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_service_account_for_all_namespaces_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ServiceAccountList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ServiceAccountList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -18484,7 +23080,10 @@ def list_service_account_for_all_namespaces_with_http_info(self, **kwargs): # n
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -18502,30 +23101,30 @@ def list_service_account_for_all_namespaces_with_http_info(self, **kwargs): # n
path_params = {}
query_params = []
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -18538,6 +23137,11 @@ def list_service_account_for_all_namespaces_with_http_info(self, **kwargs): # n
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ServiceAccountList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/serviceaccounts', 'GET',
path_params,
@@ -18546,13 +23150,14 @@ def list_service_account_for_all_namespaces_with_http_info(self, **kwargs): # n
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ServiceAccountList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_service_for_all_namespaces(self, **kwargs): # noqa: E501
"""list_service_for_all_namespaces # noqa: E501
@@ -18560,31 +23165,46 @@ def list_service_for_all_namespaces(self, **kwargs): # noqa: E501
list or watch objects of kind Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_service_for_all_namespaces(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ServiceList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ServiceList
"""
kwargs['_return_http_data_only'] = True
return self.list_service_for_all_namespaces_with_http_info(**kwargs) # noqa: E501
@@ -18595,33 +23215,54 @@ def list_service_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E50
list or watch objects of kind Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_service_for_all_namespaces_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ServiceList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ServiceList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -18644,7 +23285,10 @@ def list_service_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E50
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -18662,30 +23306,30 @@ def list_service_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E50
path_params = {}
query_params = []
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -18698,6 +23342,11 @@ def list_service_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E50
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ServiceList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/services', 'GET',
path_params,
@@ -18706,13 +23355,14 @@ def list_service_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E50
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ServiceList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespace(self, name, body, **kwargs): # noqa: E501
"""patch_namespace # noqa: E501
@@ -18720,27 +23370,38 @@ def patch_namespace(self, name, body, **kwargs): # noqa: E501
partially update the specified Namespace # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespace(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Namespace (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Namespace (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Namespace
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Namespace
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespace_with_http_info(name, body, **kwargs) # noqa: E501
@@ -18751,29 +23412,46 @@ def patch_namespace_with_http_info(self, name, body, **kwargs): # noqa: E501
partially update the specified Namespace # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespace_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Namespace (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Namespace (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Namespace, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Namespace, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -18792,7 +23470,10 @@ def patch_namespace_with_http_info(self, name, body, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -18805,12 +23486,10 @@ def patch_namespace_with_http_info(self, name, body, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespace`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespace`") # noqa: E501
collection_formats = {}
@@ -18820,18 +23499,18 @@ def patch_namespace_with_http_info(self, name, body, **kwargs): # noqa: E501
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -18844,12 +23523,22 @@ def patch_namespace_with_http_info(self, name, body, **kwargs): # noqa: E501
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Namespace",
+ 201: "V1Namespace",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{name}', 'PATCH',
path_params,
@@ -18858,13 +23547,14 @@ def patch_namespace_with_http_info(self, name, body, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Namespace', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespace_status(self, name, body, **kwargs): # noqa: E501
"""patch_namespace_status # noqa: E501
@@ -18872,27 +23562,38 @@ def patch_namespace_status(self, name, body, **kwargs): # noqa: E501
partially update status of the specified Namespace # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespace_status(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Namespace (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Namespace (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Namespace
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Namespace
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespace_status_with_http_info(name, body, **kwargs) # noqa: E501
@@ -18903,29 +23604,46 @@ def patch_namespace_status_with_http_info(self, name, body, **kwargs): # noqa:
partially update status of the specified Namespace # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespace_status_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Namespace (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Namespace (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Namespace, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Namespace, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -18944,7 +23662,10 @@ def patch_namespace_status_with_http_info(self, name, body, **kwargs): # noqa:
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -18957,12 +23678,10 @@ def patch_namespace_status_with_http_info(self, name, body, **kwargs): # noqa:
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespace_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespace_status`") # noqa: E501
collection_formats = {}
@@ -18972,18 +23691,18 @@ def patch_namespace_status_with_http_info(self, name, body, **kwargs): # noqa:
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -18996,12 +23715,22 @@ def patch_namespace_status_with_http_info(self, name, body, **kwargs): # noqa:
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Namespace",
+ 201: "V1Namespace",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{name}/status', 'PATCH',
path_params,
@@ -19010,13 +23739,14 @@ def patch_namespace_status_with_http_info(self, name, body, **kwargs): # noqa:
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Namespace', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_config_map(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_config_map # noqa: E501
@@ -19024,28 +23754,40 @@ def patch_namespaced_config_map(self, name, namespace, body, **kwargs): # noqa:
partially update the specified ConfigMap # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_config_map(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ConfigMap (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ConfigMap (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ConfigMap
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ConfigMap
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_config_map_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -19056,30 +23798,48 @@ def patch_namespaced_config_map_with_http_info(self, name, namespace, body, **kw
partially update the specified ConfigMap # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_config_map_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ConfigMap (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ConfigMap (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ConfigMap, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ConfigMap, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -19099,7 +23859,10 @@ def patch_namespaced_config_map_with_http_info(self, name, namespace, body, **kw
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -19112,16 +23875,13 @@ def patch_namespaced_config_map_with_http_info(self, name, namespace, body, **kw
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_config_map`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_config_map`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_config_map`") # noqa: E501
collection_formats = {}
@@ -19133,18 +23893,18 @@ def patch_namespaced_config_map_with_http_info(self, name, namespace, body, **kw
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -19157,12 +23917,22 @@ def patch_namespaced_config_map_with_http_info(self, name, namespace, body, **kw
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ConfigMap",
+ 201: "V1ConfigMap",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/configmaps/{name}', 'PATCH',
path_params,
@@ -19171,13 +23941,14 @@ def patch_namespaced_config_map_with_http_info(self, name, namespace, body, **kw
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ConfigMap', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_endpoints(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_endpoints # noqa: E501
@@ -19185,28 +23956,40 @@ def patch_namespaced_endpoints(self, name, namespace, body, **kwargs): # noqa:
partially update the specified Endpoints # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_endpoints(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Endpoints (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Endpoints (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Endpoints
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Endpoints
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_endpoints_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -19217,30 +24000,48 @@ def patch_namespaced_endpoints_with_http_info(self, name, namespace, body, **kwa
partially update the specified Endpoints # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_endpoints_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Endpoints (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Endpoints (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Endpoints, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Endpoints, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -19260,7 +24061,10 @@ def patch_namespaced_endpoints_with_http_info(self, name, namespace, body, **kwa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -19273,16 +24077,13 @@ def patch_namespaced_endpoints_with_http_info(self, name, namespace, body, **kwa
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_endpoints`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_endpoints`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_endpoints`") # noqa: E501
collection_formats = {}
@@ -19294,18 +24095,18 @@ def patch_namespaced_endpoints_with_http_info(self, name, namespace, body, **kwa
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -19318,12 +24119,22 @@ def patch_namespaced_endpoints_with_http_info(self, name, namespace, body, **kwa
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Endpoints",
+ 201: "V1Endpoints",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/endpoints/{name}', 'PATCH',
path_params,
@@ -19332,13 +24143,14 @@ def patch_namespaced_endpoints_with_http_info(self, name, namespace, body, **kwa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Endpoints', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_event(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_event # noqa: E501
@@ -19346,28 +24158,40 @@ def patch_namespaced_event(self, name, namespace, body, **kwargs): # noqa: E501
partially update the specified Event # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_event(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Event (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Event (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: CoreV1Event
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: CoreV1Event
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_event_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -19378,30 +24202,48 @@ def patch_namespaced_event_with_http_info(self, name, namespace, body, **kwargs)
partially update the specified Event # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_event_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Event (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Event (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(CoreV1Event, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(CoreV1Event, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -19421,7 +24263,10 @@ def patch_namespaced_event_with_http_info(self, name, namespace, body, **kwargs)
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -19434,16 +24279,13 @@ def patch_namespaced_event_with_http_info(self, name, namespace, body, **kwargs)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_event`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_event`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_event`") # noqa: E501
collection_formats = {}
@@ -19455,18 +24297,18 @@ def patch_namespaced_event_with_http_info(self, name, namespace, body, **kwargs)
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -19479,12 +24321,22 @@ def patch_namespaced_event_with_http_info(self, name, namespace, body, **kwargs)
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "CoreV1Event",
+ 201: "CoreV1Event",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/events/{name}', 'PATCH',
path_params,
@@ -19493,13 +24345,14 @@ def patch_namespaced_event_with_http_info(self, name, namespace, body, **kwargs)
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='CoreV1Event', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_limit_range(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_limit_range # noqa: E501
@@ -19507,28 +24360,40 @@ def patch_namespaced_limit_range(self, name, namespace, body, **kwargs): # noqa
partially update the specified LimitRange # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_limit_range(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the LimitRange (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the LimitRange (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1LimitRange
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1LimitRange
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_limit_range_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -19539,30 +24404,48 @@ def patch_namespaced_limit_range_with_http_info(self, name, namespace, body, **k
partially update the specified LimitRange # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_limit_range_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the LimitRange (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the LimitRange (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1LimitRange, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1LimitRange, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -19582,7 +24465,10 @@ def patch_namespaced_limit_range_with_http_info(self, name, namespace, body, **k
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -19595,16 +24481,13 @@ def patch_namespaced_limit_range_with_http_info(self, name, namespace, body, **k
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_limit_range`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_limit_range`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_limit_range`") # noqa: E501
collection_formats = {}
@@ -19616,18 +24499,18 @@ def patch_namespaced_limit_range_with_http_info(self, name, namespace, body, **k
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -19640,12 +24523,22 @@ def patch_namespaced_limit_range_with_http_info(self, name, namespace, body, **k
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1LimitRange",
+ 201: "V1LimitRange",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/limitranges/{name}', 'PATCH',
path_params,
@@ -19654,13 +24547,14 @@ def patch_namespaced_limit_range_with_http_info(self, name, namespace, body, **k
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1LimitRange', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_persistent_volume_claim(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_persistent_volume_claim # noqa: E501
@@ -19668,28 +24562,40 @@ def patch_namespaced_persistent_volume_claim(self, name, namespace, body, **kwar
partially update the specified PersistentVolumeClaim # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_persistent_volume_claim(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PersistentVolumeClaim (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the PersistentVolumeClaim (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1PersistentVolumeClaim
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1PersistentVolumeClaim
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_persistent_volume_claim_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -19700,30 +24606,48 @@ def patch_namespaced_persistent_volume_claim_with_http_info(self, name, namespac
partially update the specified PersistentVolumeClaim # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_persistent_volume_claim_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PersistentVolumeClaim (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the PersistentVolumeClaim (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1PersistentVolumeClaim, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1PersistentVolumeClaim, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -19743,7 +24667,10 @@ def patch_namespaced_persistent_volume_claim_with_http_info(self, name, namespac
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -19756,16 +24683,13 @@ def patch_namespaced_persistent_volume_claim_with_http_info(self, name, namespac
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_persistent_volume_claim`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_persistent_volume_claim`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_persistent_volume_claim`") # noqa: E501
collection_formats = {}
@@ -19777,18 +24701,18 @@ def patch_namespaced_persistent_volume_claim_with_http_info(self, name, namespac
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -19801,12 +24725,22 @@ def patch_namespaced_persistent_volume_claim_with_http_info(self, name, namespac
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1PersistentVolumeClaim",
+ 201: "V1PersistentVolumeClaim",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/persistentvolumeclaims/{name}', 'PATCH',
path_params,
@@ -19815,13 +24749,14 @@ def patch_namespaced_persistent_volume_claim_with_http_info(self, name, namespac
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1PersistentVolumeClaim', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_persistent_volume_claim_status(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_persistent_volume_claim_status # noqa: E501
@@ -19829,28 +24764,40 @@ def patch_namespaced_persistent_volume_claim_status(self, name, namespace, body,
partially update status of the specified PersistentVolumeClaim # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_persistent_volume_claim_status(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PersistentVolumeClaim (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the PersistentVolumeClaim (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1PersistentVolumeClaim
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1PersistentVolumeClaim
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_persistent_volume_claim_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -19861,30 +24808,48 @@ def patch_namespaced_persistent_volume_claim_status_with_http_info(self, name, n
partially update status of the specified PersistentVolumeClaim # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_persistent_volume_claim_status_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PersistentVolumeClaim (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the PersistentVolumeClaim (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1PersistentVolumeClaim, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1PersistentVolumeClaim, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -19904,7 +24869,10 @@ def patch_namespaced_persistent_volume_claim_status_with_http_info(self, name, n
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -19917,16 +24885,13 @@ def patch_namespaced_persistent_volume_claim_status_with_http_info(self, name, n
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_persistent_volume_claim_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_persistent_volume_claim_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_persistent_volume_claim_status`") # noqa: E501
collection_formats = {}
@@ -19938,18 +24903,18 @@ def patch_namespaced_persistent_volume_claim_status_with_http_info(self, name, n
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -19962,12 +24927,22 @@ def patch_namespaced_persistent_volume_claim_status_with_http_info(self, name, n
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1PersistentVolumeClaim",
+ 201: "V1PersistentVolumeClaim",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/persistentvolumeclaims/{name}/status', 'PATCH',
path_params,
@@ -19976,13 +24951,14 @@ def patch_namespaced_persistent_volume_claim_status_with_http_info(self, name, n
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1PersistentVolumeClaim', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_pod(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_pod # noqa: E501
@@ -19990,28 +24966,40 @@ def patch_namespaced_pod(self, name, namespace, body, **kwargs): # noqa: E501
partially update the specified Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_pod(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Pod (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Pod (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Pod
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Pod
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_pod_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -20022,30 +25010,48 @@ def patch_namespaced_pod_with_http_info(self, name, namespace, body, **kwargs):
partially update the specified Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_pod_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Pod (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Pod (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Pod, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Pod, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -20065,7 +25071,10 @@ def patch_namespaced_pod_with_http_info(self, name, namespace, body, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -20078,16 +25087,13 @@ def patch_namespaced_pod_with_http_info(self, name, namespace, body, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_pod`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_pod`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_pod`") # noqa: E501
collection_formats = {}
@@ -20099,18 +25105,18 @@ def patch_namespaced_pod_with_http_info(self, name, namespace, body, **kwargs):
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -20123,12 +25129,22 @@ def patch_namespaced_pod_with_http_info(self, name, namespace, body, **kwargs):
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Pod",
+ 201: "V1Pod",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}', 'PATCH',
path_params,
@@ -20137,13 +25153,14 @@ def patch_namespaced_pod_with_http_info(self, name, namespace, body, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Pod', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_pod_ephemeralcontainers(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_pod_ephemeralcontainers # noqa: E501
@@ -20151,28 +25168,40 @@ def patch_namespaced_pod_ephemeralcontainers(self, name, namespace, body, **kwar
partially update ephemeralcontainers of the specified Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_pod_ephemeralcontainers(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Pod (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Pod (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Pod
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Pod
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_pod_ephemeralcontainers_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -20183,30 +25212,48 @@ def patch_namespaced_pod_ephemeralcontainers_with_http_info(self, name, namespac
partially update ephemeralcontainers of the specified Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_pod_ephemeralcontainers_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Pod (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Pod (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Pod, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Pod, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -20226,7 +25273,10 @@ def patch_namespaced_pod_ephemeralcontainers_with_http_info(self, name, namespac
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -20239,16 +25289,13 @@ def patch_namespaced_pod_ephemeralcontainers_with_http_info(self, name, namespac
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_pod_ephemeralcontainers`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_pod_ephemeralcontainers`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_pod_ephemeralcontainers`") # noqa: E501
collection_formats = {}
@@ -20260,18 +25307,18 @@ def patch_namespaced_pod_ephemeralcontainers_with_http_info(self, name, namespac
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -20284,12 +25331,22 @@ def patch_namespaced_pod_ephemeralcontainers_with_http_info(self, name, namespac
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Pod",
+ 201: "V1Pod",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/ephemeralcontainers', 'PATCH',
path_params,
@@ -20298,13 +25355,14 @@ def patch_namespaced_pod_ephemeralcontainers_with_http_info(self, name, namespac
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Pod', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_pod_resize(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_pod_resize # noqa: E501
@@ -20312,28 +25370,40 @@ def patch_namespaced_pod_resize(self, name, namespace, body, **kwargs): # noqa:
partially update resize of the specified Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_pod_resize(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Pod (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Pod (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Pod
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Pod
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_pod_resize_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -20344,30 +25414,48 @@ def patch_namespaced_pod_resize_with_http_info(self, name, namespace, body, **kw
partially update resize of the specified Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_pod_resize_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Pod (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Pod (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Pod, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Pod, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -20387,7 +25475,10 @@ def patch_namespaced_pod_resize_with_http_info(self, name, namespace, body, **kw
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -20400,16 +25491,13 @@ def patch_namespaced_pod_resize_with_http_info(self, name, namespace, body, **kw
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_pod_resize`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_pod_resize`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_pod_resize`") # noqa: E501
collection_formats = {}
@@ -20421,18 +25509,18 @@ def patch_namespaced_pod_resize_with_http_info(self, name, namespace, body, **kw
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -20445,12 +25533,22 @@ def patch_namespaced_pod_resize_with_http_info(self, name, namespace, body, **kw
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Pod",
+ 201: "V1Pod",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/resize', 'PATCH',
path_params,
@@ -20459,13 +25557,14 @@ def patch_namespaced_pod_resize_with_http_info(self, name, namespace, body, **kw
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Pod', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_pod_status(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_pod_status # noqa: E501
@@ -20473,28 +25572,40 @@ def patch_namespaced_pod_status(self, name, namespace, body, **kwargs): # noqa:
partially update status of the specified Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_pod_status(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Pod (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Pod (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Pod
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Pod
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_pod_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -20505,30 +25616,48 @@ def patch_namespaced_pod_status_with_http_info(self, name, namespace, body, **kw
partially update status of the specified Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_pod_status_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Pod (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Pod (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Pod, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Pod, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -20548,7 +25677,10 @@ def patch_namespaced_pod_status_with_http_info(self, name, namespace, body, **kw
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -20561,16 +25693,13 @@ def patch_namespaced_pod_status_with_http_info(self, name, namespace, body, **kw
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_pod_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_pod_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_pod_status`") # noqa: E501
collection_formats = {}
@@ -20582,18 +25711,18 @@ def patch_namespaced_pod_status_with_http_info(self, name, namespace, body, **kw
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -20606,12 +25735,22 @@ def patch_namespaced_pod_status_with_http_info(self, name, namespace, body, **kw
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Pod",
+ 201: "V1Pod",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/status', 'PATCH',
path_params,
@@ -20620,13 +25759,14 @@ def patch_namespaced_pod_status_with_http_info(self, name, namespace, body, **kw
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Pod', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_pod_template(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_pod_template # noqa: E501
@@ -20634,28 +25774,40 @@ def patch_namespaced_pod_template(self, name, namespace, body, **kwargs): # noq
partially update the specified PodTemplate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_pod_template(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodTemplate (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the PodTemplate (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1PodTemplate
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1PodTemplate
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_pod_template_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -20666,30 +25818,48 @@ def patch_namespaced_pod_template_with_http_info(self, name, namespace, body, **
partially update the specified PodTemplate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_pod_template_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodTemplate (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the PodTemplate (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1PodTemplate, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1PodTemplate, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -20709,7 +25879,10 @@ def patch_namespaced_pod_template_with_http_info(self, name, namespace, body, **
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -20722,16 +25895,13 @@ def patch_namespaced_pod_template_with_http_info(self, name, namespace, body, **
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_pod_template`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_pod_template`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_pod_template`") # noqa: E501
collection_formats = {}
@@ -20743,18 +25913,18 @@ def patch_namespaced_pod_template_with_http_info(self, name, namespace, body, **
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -20767,12 +25937,22 @@ def patch_namespaced_pod_template_with_http_info(self, name, namespace, body, **
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1PodTemplate",
+ 201: "V1PodTemplate",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/podtemplates/{name}', 'PATCH',
path_params,
@@ -20781,13 +25961,14 @@ def patch_namespaced_pod_template_with_http_info(self, name, namespace, body, **
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1PodTemplate', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_replication_controller(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_replication_controller # noqa: E501
@@ -20795,28 +25976,40 @@ def patch_namespaced_replication_controller(self, name, namespace, body, **kwarg
partially update the specified ReplicationController # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_replication_controller(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ReplicationController (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ReplicationController (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ReplicationController
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ReplicationController
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_replication_controller_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -20827,30 +26020,48 @@ def patch_namespaced_replication_controller_with_http_info(self, name, namespace
partially update the specified ReplicationController # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_replication_controller_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ReplicationController (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ReplicationController (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ReplicationController, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ReplicationController, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -20870,7 +26081,10 @@ def patch_namespaced_replication_controller_with_http_info(self, name, namespace
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -20883,16 +26097,13 @@ def patch_namespaced_replication_controller_with_http_info(self, name, namespace
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_replication_controller`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_replication_controller`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_replication_controller`") # noqa: E501
collection_formats = {}
@@ -20904,18 +26115,18 @@ def patch_namespaced_replication_controller_with_http_info(self, name, namespace
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -20928,12 +26139,22 @@ def patch_namespaced_replication_controller_with_http_info(self, name, namespace
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ReplicationController",
+ 201: "V1ReplicationController",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/replicationcontrollers/{name}', 'PATCH',
path_params,
@@ -20942,13 +26163,14 @@ def patch_namespaced_replication_controller_with_http_info(self, name, namespace
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ReplicationController', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_replication_controller_scale(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_replication_controller_scale # noqa: E501
@@ -20956,28 +26178,40 @@ def patch_namespaced_replication_controller_scale(self, name, namespace, body, *
partially update scale of the specified ReplicationController # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_replication_controller_scale(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Scale (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Scale (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Scale
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Scale
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_replication_controller_scale_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -20988,30 +26222,48 @@ def patch_namespaced_replication_controller_scale_with_http_info(self, name, nam
partially update scale of the specified ReplicationController # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_replication_controller_scale_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Scale (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Scale (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Scale, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Scale, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -21031,7 +26283,10 @@ def patch_namespaced_replication_controller_scale_with_http_info(self, name, nam
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -21044,16 +26299,13 @@ def patch_namespaced_replication_controller_scale_with_http_info(self, name, nam
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_replication_controller_scale`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_replication_controller_scale`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_replication_controller_scale`") # noqa: E501
collection_formats = {}
@@ -21065,18 +26317,18 @@ def patch_namespaced_replication_controller_scale_with_http_info(self, name, nam
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -21089,12 +26341,22 @@ def patch_namespaced_replication_controller_scale_with_http_info(self, name, nam
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Scale",
+ 201: "V1Scale",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/replicationcontrollers/{name}/scale', 'PATCH',
path_params,
@@ -21103,13 +26365,14 @@ def patch_namespaced_replication_controller_scale_with_http_info(self, name, nam
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Scale', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_replication_controller_status(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_replication_controller_status # noqa: E501
@@ -21117,28 +26380,40 @@ def patch_namespaced_replication_controller_status(self, name, namespace, body,
partially update status of the specified ReplicationController # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_replication_controller_status(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ReplicationController (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ReplicationController (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ReplicationController
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ReplicationController
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_replication_controller_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -21149,30 +26424,48 @@ def patch_namespaced_replication_controller_status_with_http_info(self, name, na
partially update status of the specified ReplicationController # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_replication_controller_status_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ReplicationController (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ReplicationController (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ReplicationController, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ReplicationController, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -21192,7 +26485,10 @@ def patch_namespaced_replication_controller_status_with_http_info(self, name, na
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -21205,16 +26501,13 @@ def patch_namespaced_replication_controller_status_with_http_info(self, name, na
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_replication_controller_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_replication_controller_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_replication_controller_status`") # noqa: E501
collection_formats = {}
@@ -21226,18 +26519,18 @@ def patch_namespaced_replication_controller_status_with_http_info(self, name, na
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -21250,12 +26543,22 @@ def patch_namespaced_replication_controller_status_with_http_info(self, name, na
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ReplicationController",
+ 201: "V1ReplicationController",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/replicationcontrollers/{name}/status', 'PATCH',
path_params,
@@ -21264,13 +26567,14 @@ def patch_namespaced_replication_controller_status_with_http_info(self, name, na
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ReplicationController', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_resource_quota(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_resource_quota # noqa: E501
@@ -21278,28 +26582,40 @@ def patch_namespaced_resource_quota(self, name, namespace, body, **kwargs): # n
partially update the specified ResourceQuota # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_resource_quota(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ResourceQuota (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ResourceQuota (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ResourceQuota
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ResourceQuota
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_resource_quota_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -21310,30 +26626,48 @@ def patch_namespaced_resource_quota_with_http_info(self, name, namespace, body,
partially update the specified ResourceQuota # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_resource_quota_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ResourceQuota (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ResourceQuota (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ResourceQuota, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ResourceQuota, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -21353,7 +26687,10 @@ def patch_namespaced_resource_quota_with_http_info(self, name, namespace, body,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -21366,16 +26703,13 @@ def patch_namespaced_resource_quota_with_http_info(self, name, namespace, body,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_resource_quota`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_resource_quota`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_resource_quota`") # noqa: E501
collection_formats = {}
@@ -21387,18 +26721,18 @@ def patch_namespaced_resource_quota_with_http_info(self, name, namespace, body,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -21411,12 +26745,22 @@ def patch_namespaced_resource_quota_with_http_info(self, name, namespace, body,
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ResourceQuota",
+ 201: "V1ResourceQuota",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/resourcequotas/{name}', 'PATCH',
path_params,
@@ -21425,13 +26769,14 @@ def patch_namespaced_resource_quota_with_http_info(self, name, namespace, body,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ResourceQuota', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_resource_quota_status(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_resource_quota_status # noqa: E501
@@ -21439,28 +26784,40 @@ def patch_namespaced_resource_quota_status(self, name, namespace, body, **kwargs
partially update status of the specified ResourceQuota # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_resource_quota_status(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ResourceQuota (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ResourceQuota (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ResourceQuota
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ResourceQuota
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_resource_quota_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -21471,30 +26828,48 @@ def patch_namespaced_resource_quota_status_with_http_info(self, name, namespace,
partially update status of the specified ResourceQuota # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_resource_quota_status_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ResourceQuota (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ResourceQuota (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ResourceQuota, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ResourceQuota, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -21514,7 +26889,10 @@ def patch_namespaced_resource_quota_status_with_http_info(self, name, namespace,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -21527,16 +26905,13 @@ def patch_namespaced_resource_quota_status_with_http_info(self, name, namespace,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_resource_quota_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_resource_quota_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_resource_quota_status`") # noqa: E501
collection_formats = {}
@@ -21548,18 +26923,18 @@ def patch_namespaced_resource_quota_status_with_http_info(self, name, namespace,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -21572,12 +26947,22 @@ def patch_namespaced_resource_quota_status_with_http_info(self, name, namespace,
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ResourceQuota",
+ 201: "V1ResourceQuota",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/resourcequotas/{name}/status', 'PATCH',
path_params,
@@ -21586,13 +26971,14 @@ def patch_namespaced_resource_quota_status_with_http_info(self, name, namespace,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ResourceQuota', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_secret(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_secret # noqa: E501
@@ -21600,28 +26986,40 @@ def patch_namespaced_secret(self, name, namespace, body, **kwargs): # noqa: E50
partially update the specified Secret # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_secret(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Secret (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Secret (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Secret
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Secret
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_secret_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -21632,30 +27030,48 @@ def patch_namespaced_secret_with_http_info(self, name, namespace, body, **kwargs
partially update the specified Secret # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_secret_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Secret (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Secret (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Secret, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Secret, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -21675,7 +27091,10 @@ def patch_namespaced_secret_with_http_info(self, name, namespace, body, **kwargs
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -21688,16 +27107,13 @@ def patch_namespaced_secret_with_http_info(self, name, namespace, body, **kwargs
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_secret`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_secret`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_secret`") # noqa: E501
collection_formats = {}
@@ -21709,18 +27125,18 @@ def patch_namespaced_secret_with_http_info(self, name, namespace, body, **kwargs
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -21733,12 +27149,22 @@ def patch_namespaced_secret_with_http_info(self, name, namespace, body, **kwargs
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Secret",
+ 201: "V1Secret",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/secrets/{name}', 'PATCH',
path_params,
@@ -21747,13 +27173,14 @@ def patch_namespaced_secret_with_http_info(self, name, namespace, body, **kwargs
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Secret', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_service(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_service # noqa: E501
@@ -21761,28 +27188,40 @@ def patch_namespaced_service(self, name, namespace, body, **kwargs): # noqa: E5
partially update the specified Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_service(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Service (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Service (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Service
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Service
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_service_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -21793,30 +27232,48 @@ def patch_namespaced_service_with_http_info(self, name, namespace, body, **kwarg
partially update the specified Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_service_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Service (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Service (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Service, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Service, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -21836,7 +27293,10 @@ def patch_namespaced_service_with_http_info(self, name, namespace, body, **kwarg
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -21849,16 +27309,13 @@ def patch_namespaced_service_with_http_info(self, name, namespace, body, **kwarg
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_service`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_service`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_service`") # noqa: E501
collection_formats = {}
@@ -21870,18 +27327,18 @@ def patch_namespaced_service_with_http_info(self, name, namespace, body, **kwarg
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -21894,12 +27351,22 @@ def patch_namespaced_service_with_http_info(self, name, namespace, body, **kwarg
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Service",
+ 201: "V1Service",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/services/{name}', 'PATCH',
path_params,
@@ -21908,13 +27375,14 @@ def patch_namespaced_service_with_http_info(self, name, namespace, body, **kwarg
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Service', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_service_account(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_service_account # noqa: E501
@@ -21922,28 +27390,40 @@ def patch_namespaced_service_account(self, name, namespace, body, **kwargs): #
partially update the specified ServiceAccount # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_service_account(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceAccount (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ServiceAccount (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ServiceAccount
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ServiceAccount
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_service_account_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -21954,30 +27434,48 @@ def patch_namespaced_service_account_with_http_info(self, name, namespace, body,
partially update the specified ServiceAccount # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_service_account_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceAccount (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the ServiceAccount (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ServiceAccount, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ServiceAccount, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -21997,7 +27495,10 @@ def patch_namespaced_service_account_with_http_info(self, name, namespace, body,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -22010,16 +27511,13 @@ def patch_namespaced_service_account_with_http_info(self, name, namespace, body,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_service_account`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_service_account`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_service_account`") # noqa: E501
collection_formats = {}
@@ -22031,18 +27529,18 @@ def patch_namespaced_service_account_with_http_info(self, name, namespace, body,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -22055,12 +27553,22 @@ def patch_namespaced_service_account_with_http_info(self, name, namespace, body,
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ServiceAccount",
+ 201: "V1ServiceAccount",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/serviceaccounts/{name}', 'PATCH',
path_params,
@@ -22069,13 +27577,14 @@ def patch_namespaced_service_account_with_http_info(self, name, namespace, body,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ServiceAccount', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_service_status(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_service_status # noqa: E501
@@ -22083,28 +27592,40 @@ def patch_namespaced_service_status(self, name, namespace, body, **kwargs): # n
partially update status of the specified Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_service_status(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Service (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Service (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Service
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Service
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_service_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -22115,30 +27636,48 @@ def patch_namespaced_service_status_with_http_info(self, name, namespace, body,
partially update status of the specified Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_service_status_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Service (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Service (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Service, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Service, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -22158,7 +27697,10 @@ def patch_namespaced_service_status_with_http_info(self, name, namespace, body,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -22171,16 +27713,13 @@ def patch_namespaced_service_status_with_http_info(self, name, namespace, body,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_service_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_service_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_service_status`") # noqa: E501
collection_formats = {}
@@ -22192,18 +27731,18 @@ def patch_namespaced_service_status_with_http_info(self, name, namespace, body,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -22216,12 +27755,22 @@ def patch_namespaced_service_status_with_http_info(self, name, namespace, body,
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Service",
+ 201: "V1Service",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/services/{name}/status', 'PATCH',
path_params,
@@ -22230,13 +27779,14 @@ def patch_namespaced_service_status_with_http_info(self, name, namespace, body,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Service', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_node(self, name, body, **kwargs): # noqa: E501
"""patch_node # noqa: E501
@@ -22244,27 +27794,38 @@ def patch_node(self, name, body, **kwargs): # noqa: E501
partially update the specified Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_node(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Node (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Node (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Node
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Node
"""
kwargs['_return_http_data_only'] = True
return self.patch_node_with_http_info(name, body, **kwargs) # noqa: E501
@@ -22275,29 +27836,46 @@ def patch_node_with_http_info(self, name, body, **kwargs): # noqa: E501
partially update the specified Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_node_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Node (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Node (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Node, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Node, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -22316,7 +27894,10 @@ def patch_node_with_http_info(self, name, body, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -22329,12 +27910,10 @@ def patch_node_with_http_info(self, name, body, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_node`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_node`") # noqa: E501
collection_formats = {}
@@ -22344,18 +27923,18 @@ def patch_node_with_http_info(self, name, body, **kwargs): # noqa: E501
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -22368,12 +27947,22 @@ def patch_node_with_http_info(self, name, body, **kwargs): # noqa: E501
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Node",
+ 201: "V1Node",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/nodes/{name}', 'PATCH',
path_params,
@@ -22382,13 +27971,14 @@ def patch_node_with_http_info(self, name, body, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Node', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_node_status(self, name, body, **kwargs): # noqa: E501
"""patch_node_status # noqa: E501
@@ -22396,27 +27986,38 @@ def patch_node_status(self, name, body, **kwargs): # noqa: E501
partially update status of the specified Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_node_status(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Node (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Node (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Node
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Node
"""
kwargs['_return_http_data_only'] = True
return self.patch_node_status_with_http_info(name, body, **kwargs) # noqa: E501
@@ -22427,29 +28028,46 @@ def patch_node_status_with_http_info(self, name, body, **kwargs): # noqa: E501
partially update status of the specified Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_node_status_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Node (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the Node (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Node, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Node, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -22468,7 +28086,10 @@ def patch_node_status_with_http_info(self, name, body, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -22481,12 +28102,10 @@ def patch_node_status_with_http_info(self, name, body, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_node_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_node_status`") # noqa: E501
collection_formats = {}
@@ -22496,18 +28115,18 @@ def patch_node_status_with_http_info(self, name, body, **kwargs): # noqa: E501
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -22520,12 +28139,22 @@ def patch_node_status_with_http_info(self, name, body, **kwargs): # noqa: E501
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Node",
+ 201: "V1Node",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/nodes/{name}/status', 'PATCH',
path_params,
@@ -22534,13 +28163,14 @@ def patch_node_status_with_http_info(self, name, body, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Node', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_persistent_volume(self, name, body, **kwargs): # noqa: E501
"""patch_persistent_volume # noqa: E501
@@ -22548,27 +28178,38 @@ def patch_persistent_volume(self, name, body, **kwargs): # noqa: E501
partially update the specified PersistentVolume # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_persistent_volume(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PersistentVolume (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the PersistentVolume (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1PersistentVolume
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1PersistentVolume
"""
kwargs['_return_http_data_only'] = True
return self.patch_persistent_volume_with_http_info(name, body, **kwargs) # noqa: E501
@@ -22579,29 +28220,46 @@ def patch_persistent_volume_with_http_info(self, name, body, **kwargs): # noqa:
partially update the specified PersistentVolume # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_persistent_volume_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PersistentVolume (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the PersistentVolume (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1PersistentVolume, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1PersistentVolume, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -22620,7 +28278,10 @@ def patch_persistent_volume_with_http_info(self, name, body, **kwargs): # noqa:
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -22633,12 +28294,10 @@ def patch_persistent_volume_with_http_info(self, name, body, **kwargs): # noqa:
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_persistent_volume`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_persistent_volume`") # noqa: E501
collection_formats = {}
@@ -22648,18 +28307,18 @@ def patch_persistent_volume_with_http_info(self, name, body, **kwargs): # noqa:
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -22672,12 +28331,22 @@ def patch_persistent_volume_with_http_info(self, name, body, **kwargs): # noqa:
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1PersistentVolume",
+ 201: "V1PersistentVolume",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/persistentvolumes/{name}', 'PATCH',
path_params,
@@ -22686,13 +28355,14 @@ def patch_persistent_volume_with_http_info(self, name, body, **kwargs): # noqa:
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1PersistentVolume', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_persistent_volume_status(self, name, body, **kwargs): # noqa: E501
"""patch_persistent_volume_status # noqa: E501
@@ -22700,27 +28370,38 @@ def patch_persistent_volume_status(self, name, body, **kwargs): # noqa: E501
partially update status of the specified PersistentVolume # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_persistent_volume_status(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PersistentVolume (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the PersistentVolume (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1PersistentVolume
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1PersistentVolume
"""
kwargs['_return_http_data_only'] = True
return self.patch_persistent_volume_status_with_http_info(name, body, **kwargs) # noqa: E501
@@ -22731,29 +28412,46 @@ def patch_persistent_volume_status_with_http_info(self, name, body, **kwargs):
partially update status of the specified PersistentVolume # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_persistent_volume_status_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PersistentVolume (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the PersistentVolume (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1PersistentVolume, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1PersistentVolume, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -22772,7 +28470,10 @@ def patch_persistent_volume_status_with_http_info(self, name, body, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -22785,12 +28486,10 @@ def patch_persistent_volume_status_with_http_info(self, name, body, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_persistent_volume_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_persistent_volume_status`") # noqa: E501
collection_formats = {}
@@ -22800,18 +28499,18 @@ def patch_persistent_volume_status_with_http_info(self, name, body, **kwargs):
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -22824,12 +28523,22 @@ def patch_persistent_volume_status_with_http_info(self, name, body, **kwargs):
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1PersistentVolume",
+ 201: "V1PersistentVolume",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/persistentvolumes/{name}/status', 'PATCH',
path_params,
@@ -22838,13 +28547,14 @@ def patch_persistent_volume_status_with_http_info(self, name, body, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1PersistentVolume', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_component_status(self, name, **kwargs): # noqa: E501
"""read_component_status # noqa: E501
@@ -22852,22 +28562,28 @@ def read_component_status(self, name, **kwargs): # noqa: E501
read the specified ComponentStatus # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_component_status(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ComponentStatus (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ComponentStatus (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ComponentStatus
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ComponentStatus
"""
kwargs['_return_http_data_only'] = True
return self.read_component_status_with_http_info(name, **kwargs) # noqa: E501
@@ -22878,24 +28594,36 @@ def read_component_status_with_http_info(self, name, **kwargs): # noqa: E501
read the specified ComponentStatus # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_component_status_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ComponentStatus (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ComponentStatus (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ComponentStatus, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ComponentStatus, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -22909,7 +28637,10 @@ def read_component_status_with_http_info(self, name, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -22922,8 +28653,7 @@ def read_component_status_with_http_info(self, name, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_component_status`") # noqa: E501
collection_formats = {}
@@ -22933,10 +28663,10 @@ def read_component_status_with_http_info(self, name, **kwargs): # noqa: E501
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -22949,6 +28679,11 @@ def read_component_status_with_http_info(self, name, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ComponentStatus",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/componentstatuses/{name}', 'GET',
path_params,
@@ -22957,13 +28692,14 @@ def read_component_status_with_http_info(self, name, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ComponentStatus', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespace(self, name, **kwargs): # noqa: E501
"""read_namespace # noqa: E501
@@ -22971,22 +28707,28 @@ def read_namespace(self, name, **kwargs): # noqa: E501
read the specified Namespace # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespace(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Namespace (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Namespace (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Namespace
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Namespace
"""
kwargs['_return_http_data_only'] = True
return self.read_namespace_with_http_info(name, **kwargs) # noqa: E501
@@ -22997,24 +28739,36 @@ def read_namespace_with_http_info(self, name, **kwargs): # noqa: E501
read the specified Namespace # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespace_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Namespace (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Namespace (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Namespace, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Namespace, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -23028,7 +28782,10 @@ def read_namespace_with_http_info(self, name, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -23041,8 +28798,7 @@ def read_namespace_with_http_info(self, name, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespace`") # noqa: E501
collection_formats = {}
@@ -23052,10 +28808,10 @@ def read_namespace_with_http_info(self, name, **kwargs): # noqa: E501
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -23068,6 +28824,11 @@ def read_namespace_with_http_info(self, name, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Namespace",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{name}', 'GET',
path_params,
@@ -23076,13 +28837,14 @@ def read_namespace_with_http_info(self, name, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Namespace', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespace_status(self, name, **kwargs): # noqa: E501
"""read_namespace_status # noqa: E501
@@ -23090,22 +28852,28 @@ def read_namespace_status(self, name, **kwargs): # noqa: E501
read status of the specified Namespace # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespace_status(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Namespace (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Namespace (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Namespace
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Namespace
"""
kwargs['_return_http_data_only'] = True
return self.read_namespace_status_with_http_info(name, **kwargs) # noqa: E501
@@ -23116,24 +28884,36 @@ def read_namespace_status_with_http_info(self, name, **kwargs): # noqa: E501
read status of the specified Namespace # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespace_status_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Namespace (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Namespace (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Namespace, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Namespace, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -23147,7 +28927,10 @@ def read_namespace_status_with_http_info(self, name, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -23160,8 +28943,7 @@ def read_namespace_status_with_http_info(self, name, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespace_status`") # noqa: E501
collection_formats = {}
@@ -23171,10 +28953,10 @@ def read_namespace_status_with_http_info(self, name, **kwargs): # noqa: E501
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -23187,6 +28969,11 @@ def read_namespace_status_with_http_info(self, name, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Namespace",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{name}/status', 'GET',
path_params,
@@ -23195,13 +28982,14 @@ def read_namespace_status_with_http_info(self, name, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Namespace', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_config_map(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_config_map # noqa: E501
@@ -23209,23 +28997,30 @@ def read_namespaced_config_map(self, name, namespace, **kwargs): # noqa: E501
read the specified ConfigMap # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_config_map(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ConfigMap (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ConfigMap (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ConfigMap
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ConfigMap
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_config_map_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -23236,25 +29031,38 @@ def read_namespaced_config_map_with_http_info(self, name, namespace, **kwargs):
read the specified ConfigMap # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_config_map_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ConfigMap (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ConfigMap (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ConfigMap, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ConfigMap, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -23269,7 +29077,10 @@ def read_namespaced_config_map_with_http_info(self, name, namespace, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -23282,12 +29093,10 @@ def read_namespaced_config_map_with_http_info(self, name, namespace, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_config_map`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_config_map`") # noqa: E501
collection_formats = {}
@@ -23299,10 +29108,10 @@ def read_namespaced_config_map_with_http_info(self, name, namespace, **kwargs):
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -23315,6 +29124,11 @@ def read_namespaced_config_map_with_http_info(self, name, namespace, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ConfigMap",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/configmaps/{name}', 'GET',
path_params,
@@ -23323,13 +29137,14 @@ def read_namespaced_config_map_with_http_info(self, name, namespace, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ConfigMap', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_endpoints(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_endpoints # noqa: E501
@@ -23337,23 +29152,30 @@ def read_namespaced_endpoints(self, name, namespace, **kwargs): # noqa: E501
read the specified Endpoints # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_endpoints(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Endpoints (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Endpoints (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Endpoints
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Endpoints
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_endpoints_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -23364,25 +29186,38 @@ def read_namespaced_endpoints_with_http_info(self, name, namespace, **kwargs):
read the specified Endpoints # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_endpoints_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Endpoints (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Endpoints (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Endpoints, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Endpoints, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -23397,7 +29232,10 @@ def read_namespaced_endpoints_with_http_info(self, name, namespace, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -23410,12 +29248,10 @@ def read_namespaced_endpoints_with_http_info(self, name, namespace, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_endpoints`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_endpoints`") # noqa: E501
collection_formats = {}
@@ -23427,10 +29263,10 @@ def read_namespaced_endpoints_with_http_info(self, name, namespace, **kwargs):
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -23443,6 +29279,11 @@ def read_namespaced_endpoints_with_http_info(self, name, namespace, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Endpoints",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/endpoints/{name}', 'GET',
path_params,
@@ -23451,13 +29292,14 @@ def read_namespaced_endpoints_with_http_info(self, name, namespace, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Endpoints', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_event(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_event # noqa: E501
@@ -23465,23 +29307,30 @@ def read_namespaced_event(self, name, namespace, **kwargs): # noqa: E501
read the specified Event # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_event(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Event (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Event (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: CoreV1Event
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: CoreV1Event
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_event_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -23492,25 +29341,38 @@ def read_namespaced_event_with_http_info(self, name, namespace, **kwargs): # no
read the specified Event # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_event_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Event (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Event (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(CoreV1Event, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(CoreV1Event, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -23525,7 +29387,10 @@ def read_namespaced_event_with_http_info(self, name, namespace, **kwargs): # no
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -23538,12 +29403,10 @@ def read_namespaced_event_with_http_info(self, name, namespace, **kwargs): # no
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_event`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_event`") # noqa: E501
collection_formats = {}
@@ -23555,10 +29418,10 @@ def read_namespaced_event_with_http_info(self, name, namespace, **kwargs): # no
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -23571,6 +29434,11 @@ def read_namespaced_event_with_http_info(self, name, namespace, **kwargs): # no
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "CoreV1Event",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/events/{name}', 'GET',
path_params,
@@ -23579,13 +29447,14 @@ def read_namespaced_event_with_http_info(self, name, namespace, **kwargs): # no
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='CoreV1Event', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_limit_range(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_limit_range # noqa: E501
@@ -23593,23 +29462,30 @@ def read_namespaced_limit_range(self, name, namespace, **kwargs): # noqa: E501
read the specified LimitRange # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_limit_range(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the LimitRange (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the LimitRange (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1LimitRange
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1LimitRange
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_limit_range_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -23620,25 +29496,38 @@ def read_namespaced_limit_range_with_http_info(self, name, namespace, **kwargs):
read the specified LimitRange # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_limit_range_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the LimitRange (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the LimitRange (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1LimitRange, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1LimitRange, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -23653,7 +29542,10 @@ def read_namespaced_limit_range_with_http_info(self, name, namespace, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -23666,12 +29558,10 @@ def read_namespaced_limit_range_with_http_info(self, name, namespace, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_limit_range`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_limit_range`") # noqa: E501
collection_formats = {}
@@ -23683,10 +29573,10 @@ def read_namespaced_limit_range_with_http_info(self, name, namespace, **kwargs):
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -23699,6 +29589,11 @@ def read_namespaced_limit_range_with_http_info(self, name, namespace, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1LimitRange",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/limitranges/{name}', 'GET',
path_params,
@@ -23707,13 +29602,14 @@ def read_namespaced_limit_range_with_http_info(self, name, namespace, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1LimitRange', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_persistent_volume_claim(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_persistent_volume_claim # noqa: E501
@@ -23721,23 +29617,30 @@ def read_namespaced_persistent_volume_claim(self, name, namespace, **kwargs): #
read the specified PersistentVolumeClaim # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_persistent_volume_claim(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PersistentVolumeClaim (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the PersistentVolumeClaim (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1PersistentVolumeClaim
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1PersistentVolumeClaim
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_persistent_volume_claim_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -23748,25 +29651,38 @@ def read_namespaced_persistent_volume_claim_with_http_info(self, name, namespace
read the specified PersistentVolumeClaim # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_persistent_volume_claim_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PersistentVolumeClaim (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the PersistentVolumeClaim (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1PersistentVolumeClaim, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1PersistentVolumeClaim, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -23781,7 +29697,10 @@ def read_namespaced_persistent_volume_claim_with_http_info(self, name, namespace
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -23794,12 +29713,10 @@ def read_namespaced_persistent_volume_claim_with_http_info(self, name, namespace
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_persistent_volume_claim`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_persistent_volume_claim`") # noqa: E501
collection_formats = {}
@@ -23811,10 +29728,10 @@ def read_namespaced_persistent_volume_claim_with_http_info(self, name, namespace
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -23827,6 +29744,11 @@ def read_namespaced_persistent_volume_claim_with_http_info(self, name, namespace
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1PersistentVolumeClaim",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/persistentvolumeclaims/{name}', 'GET',
path_params,
@@ -23835,13 +29757,14 @@ def read_namespaced_persistent_volume_claim_with_http_info(self, name, namespace
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1PersistentVolumeClaim', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_persistent_volume_claim_status(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_persistent_volume_claim_status # noqa: E501
@@ -23849,23 +29772,30 @@ def read_namespaced_persistent_volume_claim_status(self, name, namespace, **kwar
read status of the specified PersistentVolumeClaim # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_persistent_volume_claim_status(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PersistentVolumeClaim (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the PersistentVolumeClaim (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1PersistentVolumeClaim
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1PersistentVolumeClaim
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_persistent_volume_claim_status_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -23876,25 +29806,38 @@ def read_namespaced_persistent_volume_claim_status_with_http_info(self, name, na
read status of the specified PersistentVolumeClaim # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_persistent_volume_claim_status_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PersistentVolumeClaim (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the PersistentVolumeClaim (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1PersistentVolumeClaim, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1PersistentVolumeClaim, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -23909,7 +29852,10 @@ def read_namespaced_persistent_volume_claim_status_with_http_info(self, name, na
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -23922,12 +29868,10 @@ def read_namespaced_persistent_volume_claim_status_with_http_info(self, name, na
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_persistent_volume_claim_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_persistent_volume_claim_status`") # noqa: E501
collection_formats = {}
@@ -23939,10 +29883,10 @@ def read_namespaced_persistent_volume_claim_status_with_http_info(self, name, na
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -23955,6 +29899,11 @@ def read_namespaced_persistent_volume_claim_status_with_http_info(self, name, na
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1PersistentVolumeClaim",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/persistentvolumeclaims/{name}/status', 'GET',
path_params,
@@ -23963,13 +29912,14 @@ def read_namespaced_persistent_volume_claim_status_with_http_info(self, name, na
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1PersistentVolumeClaim', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_pod(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_pod # noqa: E501
@@ -23977,23 +29927,30 @@ def read_namespaced_pod(self, name, namespace, **kwargs): # noqa: E501
read the specified Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_pod(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Pod (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Pod (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Pod
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Pod
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_pod_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -24004,25 +29961,38 @@ def read_namespaced_pod_with_http_info(self, name, namespace, **kwargs): # noqa
read the specified Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_pod_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Pod (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Pod (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Pod, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Pod, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -24037,7 +30007,10 @@ def read_namespaced_pod_with_http_info(self, name, namespace, **kwargs): # noqa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -24050,12 +30023,10 @@ def read_namespaced_pod_with_http_info(self, name, namespace, **kwargs): # noqa
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_pod`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_pod`") # noqa: E501
collection_formats = {}
@@ -24067,10 +30038,10 @@ def read_namespaced_pod_with_http_info(self, name, namespace, **kwargs): # noqa
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -24083,6 +30054,11 @@ def read_namespaced_pod_with_http_info(self, name, namespace, **kwargs): # noqa
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Pod",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}', 'GET',
path_params,
@@ -24091,13 +30067,14 @@ def read_namespaced_pod_with_http_info(self, name, namespace, **kwargs): # noqa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Pod', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_pod_ephemeralcontainers(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_pod_ephemeralcontainers # noqa: E501
@@ -24105,23 +30082,30 @@ def read_namespaced_pod_ephemeralcontainers(self, name, namespace, **kwargs): #
read ephemeralcontainers of the specified Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_pod_ephemeralcontainers(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Pod (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Pod (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Pod
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Pod
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_pod_ephemeralcontainers_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -24132,25 +30116,38 @@ def read_namespaced_pod_ephemeralcontainers_with_http_info(self, name, namespace
read ephemeralcontainers of the specified Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_pod_ephemeralcontainers_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Pod (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Pod (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Pod, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Pod, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -24165,7 +30162,10 @@ def read_namespaced_pod_ephemeralcontainers_with_http_info(self, name, namespace
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -24178,12 +30178,10 @@ def read_namespaced_pod_ephemeralcontainers_with_http_info(self, name, namespace
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_pod_ephemeralcontainers`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_pod_ephemeralcontainers`") # noqa: E501
collection_formats = {}
@@ -24195,10 +30193,10 @@ def read_namespaced_pod_ephemeralcontainers_with_http_info(self, name, namespace
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -24211,6 +30209,11 @@ def read_namespaced_pod_ephemeralcontainers_with_http_info(self, name, namespace
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Pod",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/ephemeralcontainers', 'GET',
path_params,
@@ -24219,13 +30222,14 @@ def read_namespaced_pod_ephemeralcontainers_with_http_info(self, name, namespace
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Pod', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_pod_log(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_pod_log # noqa: E501
@@ -24233,32 +30237,48 @@ def read_namespaced_pod_log(self, name, namespace, **kwargs): # noqa: E501
read log of the specified Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_pod_log(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Pod (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str container: The container for which to stream logs. Defaults to only container if there is one container in the pod.
- :param bool follow: Follow the log stream of the pod. Defaults to false.
- :param bool insecure_skip_tls_verify_backend: insecureSkipTLSVerifyBackend indicates that the apiserver should not confirm the validity of the serving certificate of the backend it is connecting to. This will make the HTTPS connection between the apiserver and the backend insecure. This means the apiserver cannot verify the log data it is receiving came from the real kubelet. If the kubelet is configured to verify the apiserver's TLS credentials, it does not mean the connection to the real kubelet is vulnerable to a man in the middle attack (e.g. an attacker could not intercept the actual log data coming from the real kubelet).
- :param int limit_bytes: If set, the number of bytes to read from the server before terminating the log output. This may not display a complete final line of logging, and may return slightly more or slightly less than the specified limit.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool previous: Return previous terminated container logs. Defaults to false.
- :param int since_seconds: A relative time in seconds before the current time from which to show logs. If this value precedes the time a pod was started, only logs since the pod start will be returned. If this value is in the future, no logs will be returned. Only one of sinceSeconds or sinceTime may be specified.
- :param str stream: Specify which container log stream to return to the client. Acceptable values are \"All\", \"Stdout\" and \"Stderr\". If not specified, \"All\" is used, and both stdout and stderr are returned interleaved. Note that when \"TailLines\" is specified, \"Stream\" can only be set to nil or \"All\".
- :param int tail_lines: If set, the number of lines from the end of the logs to show. If not specified, logs are shown from the creation of the container or sinceSeconds or sinceTime. Note that when \"TailLines\" is specified, \"Stream\" can only be set to nil or \"All\".
- :param bool timestamps: If true, add an RFC3339 or RFC3339Nano timestamp at the beginning of every line of log output. Defaults to false.
+ :param name: name of the Pod (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param container: The container for which to stream logs. Defaults to only container if there is one container in the pod.
+ :type container: str
+ :param follow: Follow the log stream of the pod. Defaults to false.
+ :type follow: bool
+ :param insecure_skip_tls_verify_backend: insecureSkipTLSVerifyBackend indicates that the apiserver should not confirm the validity of the serving certificate of the backend it is connecting to. This will make the HTTPS connection between the apiserver and the backend insecure. This means the apiserver cannot verify the log data it is receiving came from the real kubelet. If the kubelet is configured to verify the apiserver's TLS credentials, it does not mean the connection to the real kubelet is vulnerable to a man in the middle attack (e.g. an attacker could not intercept the actual log data coming from the real kubelet).
+ :type insecure_skip_tls_verify_backend: bool
+ :param limit_bytes: If set, the number of bytes to read from the server before terminating the log output. This may not display a complete final line of logging, and may return slightly more or slightly less than the specified limit.
+ :type limit_bytes: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param previous: Return previous terminated container logs. Defaults to false.
+ :type previous: bool
+ :param since_seconds: A relative time in seconds before the current time from which to show logs. If this value precedes the time a pod was started, only logs since the pod start will be returned. If this value is in the future, no logs will be returned. Only one of sinceSeconds or sinceTime may be specified.
+ :type since_seconds: int
+ :param stream: Specify which container log stream to return to the client. Acceptable values are \"All\", \"Stdout\" and \"Stderr\". If not specified, \"All\" is used, and both stdout and stderr are returned interleaved. Note that when \"TailLines\" is specified, \"Stream\" can only be set to nil or \"All\".
+ :type stream: str
+ :param tail_lines: If set, the number of lines from the end of the logs to show. If not specified, logs are shown from the creation of the container or sinceSeconds or sinceTime. Note that when \"TailLines\" is specified, \"Stream\" can only be set to nil or \"All\".
+ :type tail_lines: int
+ :param timestamps: If true, add an RFC3339 or RFC3339Nano timestamp at the beginning of every line of log output. Defaults to false.
+ :type timestamps: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: str
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: str
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_pod_log_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -24269,34 +30289,56 @@ def read_namespaced_pod_log_with_http_info(self, name, namespace, **kwargs): #
read log of the specified Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_pod_log_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Pod (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str container: The container for which to stream logs. Defaults to only container if there is one container in the pod.
- :param bool follow: Follow the log stream of the pod. Defaults to false.
- :param bool insecure_skip_tls_verify_backend: insecureSkipTLSVerifyBackend indicates that the apiserver should not confirm the validity of the serving certificate of the backend it is connecting to. This will make the HTTPS connection between the apiserver and the backend insecure. This means the apiserver cannot verify the log data it is receiving came from the real kubelet. If the kubelet is configured to verify the apiserver's TLS credentials, it does not mean the connection to the real kubelet is vulnerable to a man in the middle attack (e.g. an attacker could not intercept the actual log data coming from the real kubelet).
- :param int limit_bytes: If set, the number of bytes to read from the server before terminating the log output. This may not display a complete final line of logging, and may return slightly more or slightly less than the specified limit.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool previous: Return previous terminated container logs. Defaults to false.
- :param int since_seconds: A relative time in seconds before the current time from which to show logs. If this value precedes the time a pod was started, only logs since the pod start will be returned. If this value is in the future, no logs will be returned. Only one of sinceSeconds or sinceTime may be specified.
- :param str stream: Specify which container log stream to return to the client. Acceptable values are \"All\", \"Stdout\" and \"Stderr\". If not specified, \"All\" is used, and both stdout and stderr are returned interleaved. Note that when \"TailLines\" is specified, \"Stream\" can only be set to nil or \"All\".
- :param int tail_lines: If set, the number of lines from the end of the logs to show. If not specified, logs are shown from the creation of the container or sinceSeconds or sinceTime. Note that when \"TailLines\" is specified, \"Stream\" can only be set to nil or \"All\".
- :param bool timestamps: If true, add an RFC3339 or RFC3339Nano timestamp at the beginning of every line of log output. Defaults to false.
+ :param name: name of the Pod (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param container: The container for which to stream logs. Defaults to only container if there is one container in the pod.
+ :type container: str
+ :param follow: Follow the log stream of the pod. Defaults to false.
+ :type follow: bool
+ :param insecure_skip_tls_verify_backend: insecureSkipTLSVerifyBackend indicates that the apiserver should not confirm the validity of the serving certificate of the backend it is connecting to. This will make the HTTPS connection between the apiserver and the backend insecure. This means the apiserver cannot verify the log data it is receiving came from the real kubelet. If the kubelet is configured to verify the apiserver's TLS credentials, it does not mean the connection to the real kubelet is vulnerable to a man in the middle attack (e.g. an attacker could not intercept the actual log data coming from the real kubelet).
+ :type insecure_skip_tls_verify_backend: bool
+ :param limit_bytes: If set, the number of bytes to read from the server before terminating the log output. This may not display a complete final line of logging, and may return slightly more or slightly less than the specified limit.
+ :type limit_bytes: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param previous: Return previous terminated container logs. Defaults to false.
+ :type previous: bool
+ :param since_seconds: A relative time in seconds before the current time from which to show logs. If this value precedes the time a pod was started, only logs since the pod start will be returned. If this value is in the future, no logs will be returned. Only one of sinceSeconds or sinceTime may be specified.
+ :type since_seconds: int
+ :param stream: Specify which container log stream to return to the client. Acceptable values are \"All\", \"Stdout\" and \"Stderr\". If not specified, \"All\" is used, and both stdout and stderr are returned interleaved. Note that when \"TailLines\" is specified, \"Stream\" can only be set to nil or \"All\".
+ :type stream: str
+ :param tail_lines: If set, the number of lines from the end of the logs to show. If not specified, logs are shown from the creation of the container or sinceSeconds or sinceTime. Note that when \"TailLines\" is specified, \"Stream\" can only be set to nil or \"All\".
+ :type tail_lines: int
+ :param timestamps: If true, add an RFC3339 or RFC3339Nano timestamp at the beginning of every line of log output. Defaults to false.
+ :type timestamps: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -24320,7 +30362,10 @@ def read_namespaced_pod_log_with_http_info(self, name, namespace, **kwargs): #
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -24333,12 +30378,10 @@ def read_namespaced_pod_log_with_http_info(self, name, namespace, **kwargs): #
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_pod_log`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_pod_log`") # noqa: E501
collection_formats = {}
@@ -24350,28 +30393,28 @@ def read_namespaced_pod_log_with_http_info(self, name, namespace, **kwargs): #
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'container' in local_var_params and local_var_params['container'] is not None: # noqa: E501
+ if local_var_params.get('container') is not None: # noqa: E501
query_params.append(('container', local_var_params['container'])) # noqa: E501
- if 'follow' in local_var_params and local_var_params['follow'] is not None: # noqa: E501
+ if local_var_params.get('follow') is not None: # noqa: E501
query_params.append(('follow', local_var_params['follow'])) # noqa: E501
- if 'insecure_skip_tls_verify_backend' in local_var_params and local_var_params['insecure_skip_tls_verify_backend'] is not None: # noqa: E501
+ if local_var_params.get('insecure_skip_tls_verify_backend') is not None: # noqa: E501
query_params.append(('insecureSkipTLSVerifyBackend', local_var_params['insecure_skip_tls_verify_backend'])) # noqa: E501
- if 'limit_bytes' in local_var_params and local_var_params['limit_bytes'] is not None: # noqa: E501
+ if local_var_params.get('limit_bytes') is not None: # noqa: E501
query_params.append(('limitBytes', local_var_params['limit_bytes'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'previous' in local_var_params and local_var_params['previous'] is not None: # noqa: E501
+ if local_var_params.get('previous') is not None: # noqa: E501
query_params.append(('previous', local_var_params['previous'])) # noqa: E501
- if 'since_seconds' in local_var_params and local_var_params['since_seconds'] is not None: # noqa: E501
+ if local_var_params.get('since_seconds') is not None: # noqa: E501
query_params.append(('sinceSeconds', local_var_params['since_seconds'])) # noqa: E501
- if 'stream' in local_var_params and local_var_params['stream'] is not None: # noqa: E501
+ if local_var_params.get('stream') is not None: # noqa: E501
query_params.append(('stream', local_var_params['stream'])) # noqa: E501
- if 'tail_lines' in local_var_params and local_var_params['tail_lines'] is not None: # noqa: E501
+ if local_var_params.get('tail_lines') is not None: # noqa: E501
query_params.append(('tailLines', local_var_params['tail_lines'])) # noqa: E501
- if 'timestamps' in local_var_params and local_var_params['timestamps'] is not None: # noqa: E501
+ if local_var_params.get('timestamps') is not None: # noqa: E501
query_params.append(('timestamps', local_var_params['timestamps'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -24384,6 +30427,11 @@ def read_namespaced_pod_log_with_http_info(self, name, namespace, **kwargs): #
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "str",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/log', 'GET',
path_params,
@@ -24392,13 +30440,14 @@ def read_namespaced_pod_log_with_http_info(self, name, namespace, **kwargs): #
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='str', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_pod_resize(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_pod_resize # noqa: E501
@@ -24406,23 +30455,30 @@ def read_namespaced_pod_resize(self, name, namespace, **kwargs): # noqa: E501
read resize of the specified Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_pod_resize(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Pod (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Pod (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Pod
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Pod
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_pod_resize_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -24433,25 +30489,38 @@ def read_namespaced_pod_resize_with_http_info(self, name, namespace, **kwargs):
read resize of the specified Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_pod_resize_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Pod (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Pod (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Pod, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Pod, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -24466,7 +30535,10 @@ def read_namespaced_pod_resize_with_http_info(self, name, namespace, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -24479,12 +30551,10 @@ def read_namespaced_pod_resize_with_http_info(self, name, namespace, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_pod_resize`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_pod_resize`") # noqa: E501
collection_formats = {}
@@ -24496,10 +30566,10 @@ def read_namespaced_pod_resize_with_http_info(self, name, namespace, **kwargs):
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -24512,6 +30582,11 @@ def read_namespaced_pod_resize_with_http_info(self, name, namespace, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Pod",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/resize', 'GET',
path_params,
@@ -24520,13 +30595,14 @@ def read_namespaced_pod_resize_with_http_info(self, name, namespace, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Pod', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_pod_status(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_pod_status # noqa: E501
@@ -24534,23 +30610,30 @@ def read_namespaced_pod_status(self, name, namespace, **kwargs): # noqa: E501
read status of the specified Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_pod_status(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Pod (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Pod (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Pod
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Pod
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_pod_status_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -24561,25 +30644,38 @@ def read_namespaced_pod_status_with_http_info(self, name, namespace, **kwargs):
read status of the specified Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_pod_status_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Pod (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Pod (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Pod, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Pod, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -24594,7 +30690,10 @@ def read_namespaced_pod_status_with_http_info(self, name, namespace, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -24607,12 +30706,10 @@ def read_namespaced_pod_status_with_http_info(self, name, namespace, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_pod_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_pod_status`") # noqa: E501
collection_formats = {}
@@ -24624,10 +30721,10 @@ def read_namespaced_pod_status_with_http_info(self, name, namespace, **kwargs):
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -24640,6 +30737,11 @@ def read_namespaced_pod_status_with_http_info(self, name, namespace, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Pod",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/status', 'GET',
path_params,
@@ -24648,13 +30750,14 @@ def read_namespaced_pod_status_with_http_info(self, name, namespace, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Pod', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_pod_template(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_pod_template # noqa: E501
@@ -24662,23 +30765,30 @@ def read_namespaced_pod_template(self, name, namespace, **kwargs): # noqa: E501
read the specified PodTemplate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_pod_template(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodTemplate (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the PodTemplate (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1PodTemplate
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1PodTemplate
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_pod_template_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -24689,25 +30799,38 @@ def read_namespaced_pod_template_with_http_info(self, name, namespace, **kwargs)
read the specified PodTemplate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_pod_template_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodTemplate (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the PodTemplate (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1PodTemplate, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1PodTemplate, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -24722,7 +30845,10 @@ def read_namespaced_pod_template_with_http_info(self, name, namespace, **kwargs)
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -24735,12 +30861,10 @@ def read_namespaced_pod_template_with_http_info(self, name, namespace, **kwargs)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_pod_template`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_pod_template`") # noqa: E501
collection_formats = {}
@@ -24752,10 +30876,10 @@ def read_namespaced_pod_template_with_http_info(self, name, namespace, **kwargs)
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -24768,6 +30892,11 @@ def read_namespaced_pod_template_with_http_info(self, name, namespace, **kwargs)
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1PodTemplate",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/podtemplates/{name}', 'GET',
path_params,
@@ -24776,13 +30905,14 @@ def read_namespaced_pod_template_with_http_info(self, name, namespace, **kwargs)
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1PodTemplate', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_replication_controller(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_replication_controller # noqa: E501
@@ -24790,23 +30920,30 @@ def read_namespaced_replication_controller(self, name, namespace, **kwargs): #
read the specified ReplicationController # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_replication_controller(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ReplicationController (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ReplicationController (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ReplicationController
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ReplicationController
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_replication_controller_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -24817,25 +30954,38 @@ def read_namespaced_replication_controller_with_http_info(self, name, namespace,
read the specified ReplicationController # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_replication_controller_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ReplicationController (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ReplicationController (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ReplicationController, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ReplicationController, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -24850,7 +31000,10 @@ def read_namespaced_replication_controller_with_http_info(self, name, namespace,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -24863,12 +31016,10 @@ def read_namespaced_replication_controller_with_http_info(self, name, namespace,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_replication_controller`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_replication_controller`") # noqa: E501
collection_formats = {}
@@ -24880,10 +31031,10 @@ def read_namespaced_replication_controller_with_http_info(self, name, namespace,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -24896,6 +31047,11 @@ def read_namespaced_replication_controller_with_http_info(self, name, namespace,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ReplicationController",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/replicationcontrollers/{name}', 'GET',
path_params,
@@ -24904,13 +31060,14 @@ def read_namespaced_replication_controller_with_http_info(self, name, namespace,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ReplicationController', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_replication_controller_scale(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_replication_controller_scale # noqa: E501
@@ -24918,23 +31075,30 @@ def read_namespaced_replication_controller_scale(self, name, namespace, **kwargs
read scale of the specified ReplicationController # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_replication_controller_scale(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Scale (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Scale (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Scale
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Scale
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_replication_controller_scale_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -24945,25 +31109,38 @@ def read_namespaced_replication_controller_scale_with_http_info(self, name, name
read scale of the specified ReplicationController # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_replication_controller_scale_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Scale (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Scale (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Scale, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Scale, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -24978,7 +31155,10 @@ def read_namespaced_replication_controller_scale_with_http_info(self, name, name
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -24991,12 +31171,10 @@ def read_namespaced_replication_controller_scale_with_http_info(self, name, name
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_replication_controller_scale`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_replication_controller_scale`") # noqa: E501
collection_formats = {}
@@ -25008,10 +31186,10 @@ def read_namespaced_replication_controller_scale_with_http_info(self, name, name
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -25024,6 +31202,11 @@ def read_namespaced_replication_controller_scale_with_http_info(self, name, name
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Scale",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/replicationcontrollers/{name}/scale', 'GET',
path_params,
@@ -25032,13 +31215,14 @@ def read_namespaced_replication_controller_scale_with_http_info(self, name, name
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Scale', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_replication_controller_status(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_replication_controller_status # noqa: E501
@@ -25046,23 +31230,30 @@ def read_namespaced_replication_controller_status(self, name, namespace, **kwarg
read status of the specified ReplicationController # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_replication_controller_status(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ReplicationController (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ReplicationController (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ReplicationController
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ReplicationController
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_replication_controller_status_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -25073,25 +31264,38 @@ def read_namespaced_replication_controller_status_with_http_info(self, name, nam
read status of the specified ReplicationController # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_replication_controller_status_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ReplicationController (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ReplicationController (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ReplicationController, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ReplicationController, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -25106,7 +31310,10 @@ def read_namespaced_replication_controller_status_with_http_info(self, name, nam
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -25119,12 +31326,10 @@ def read_namespaced_replication_controller_status_with_http_info(self, name, nam
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_replication_controller_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_replication_controller_status`") # noqa: E501
collection_formats = {}
@@ -25136,10 +31341,10 @@ def read_namespaced_replication_controller_status_with_http_info(self, name, nam
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -25152,6 +31357,11 @@ def read_namespaced_replication_controller_status_with_http_info(self, name, nam
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ReplicationController",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/replicationcontrollers/{name}/status', 'GET',
path_params,
@@ -25160,13 +31370,14 @@ def read_namespaced_replication_controller_status_with_http_info(self, name, nam
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ReplicationController', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_resource_quota(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_resource_quota # noqa: E501
@@ -25174,23 +31385,30 @@ def read_namespaced_resource_quota(self, name, namespace, **kwargs): # noqa: E5
read the specified ResourceQuota # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_resource_quota(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ResourceQuota (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ResourceQuota (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ResourceQuota
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ResourceQuota
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_resource_quota_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -25201,25 +31419,38 @@ def read_namespaced_resource_quota_with_http_info(self, name, namespace, **kwarg
read the specified ResourceQuota # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_resource_quota_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ResourceQuota (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ResourceQuota (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ResourceQuota, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ResourceQuota, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -25234,7 +31465,10 @@ def read_namespaced_resource_quota_with_http_info(self, name, namespace, **kwarg
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -25247,12 +31481,10 @@ def read_namespaced_resource_quota_with_http_info(self, name, namespace, **kwarg
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_resource_quota`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_resource_quota`") # noqa: E501
collection_formats = {}
@@ -25264,10 +31496,10 @@ def read_namespaced_resource_quota_with_http_info(self, name, namespace, **kwarg
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -25280,6 +31512,11 @@ def read_namespaced_resource_quota_with_http_info(self, name, namespace, **kwarg
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ResourceQuota",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/resourcequotas/{name}', 'GET',
path_params,
@@ -25288,13 +31525,14 @@ def read_namespaced_resource_quota_with_http_info(self, name, namespace, **kwarg
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ResourceQuota', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_resource_quota_status(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_resource_quota_status # noqa: E501
@@ -25302,23 +31540,30 @@ def read_namespaced_resource_quota_status(self, name, namespace, **kwargs): # n
read status of the specified ResourceQuota # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_resource_quota_status(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ResourceQuota (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ResourceQuota (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ResourceQuota
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ResourceQuota
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_resource_quota_status_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -25329,25 +31574,38 @@ def read_namespaced_resource_quota_status_with_http_info(self, name, namespace,
read status of the specified ResourceQuota # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_resource_quota_status_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ResourceQuota (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ResourceQuota (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ResourceQuota, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ResourceQuota, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -25362,7 +31620,10 @@ def read_namespaced_resource_quota_status_with_http_info(self, name, namespace,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -25375,12 +31636,10 @@ def read_namespaced_resource_quota_status_with_http_info(self, name, namespace,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_resource_quota_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_resource_quota_status`") # noqa: E501
collection_formats = {}
@@ -25392,10 +31651,10 @@ def read_namespaced_resource_quota_status_with_http_info(self, name, namespace,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -25408,6 +31667,11 @@ def read_namespaced_resource_quota_status_with_http_info(self, name, namespace,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ResourceQuota",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/resourcequotas/{name}/status', 'GET',
path_params,
@@ -25416,13 +31680,14 @@ def read_namespaced_resource_quota_status_with_http_info(self, name, namespace,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ResourceQuota', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_secret(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_secret # noqa: E501
@@ -25430,23 +31695,30 @@ def read_namespaced_secret(self, name, namespace, **kwargs): # noqa: E501
read the specified Secret # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_secret(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Secret (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Secret (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Secret
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Secret
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_secret_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -25457,25 +31729,38 @@ def read_namespaced_secret_with_http_info(self, name, namespace, **kwargs): # n
read the specified Secret # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_secret_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Secret (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Secret (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Secret, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Secret, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -25490,7 +31775,10 @@ def read_namespaced_secret_with_http_info(self, name, namespace, **kwargs): # n
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -25503,12 +31791,10 @@ def read_namespaced_secret_with_http_info(self, name, namespace, **kwargs): # n
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_secret`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_secret`") # noqa: E501
collection_formats = {}
@@ -25520,10 +31806,10 @@ def read_namespaced_secret_with_http_info(self, name, namespace, **kwargs): # n
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -25536,6 +31822,11 @@ def read_namespaced_secret_with_http_info(self, name, namespace, **kwargs): # n
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Secret",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/secrets/{name}', 'GET',
path_params,
@@ -25544,13 +31835,14 @@ def read_namespaced_secret_with_http_info(self, name, namespace, **kwargs): # n
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Secret', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_service(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_service # noqa: E501
@@ -25558,23 +31850,30 @@ def read_namespaced_service(self, name, namespace, **kwargs): # noqa: E501
read the specified Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_service(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Service (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Service (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Service
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Service
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_service_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -25585,25 +31884,38 @@ def read_namespaced_service_with_http_info(self, name, namespace, **kwargs): #
read the specified Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_service_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Service (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Service (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Service, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Service, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -25618,7 +31930,10 @@ def read_namespaced_service_with_http_info(self, name, namespace, **kwargs): #
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -25631,12 +31946,10 @@ def read_namespaced_service_with_http_info(self, name, namespace, **kwargs): #
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_service`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_service`") # noqa: E501
collection_formats = {}
@@ -25648,10 +31961,10 @@ def read_namespaced_service_with_http_info(self, name, namespace, **kwargs): #
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -25664,6 +31977,11 @@ def read_namespaced_service_with_http_info(self, name, namespace, **kwargs): #
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Service",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/services/{name}', 'GET',
path_params,
@@ -25672,13 +31990,14 @@ def read_namespaced_service_with_http_info(self, name, namespace, **kwargs): #
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Service', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_service_account(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_service_account # noqa: E501
@@ -25686,23 +32005,30 @@ def read_namespaced_service_account(self, name, namespace, **kwargs): # noqa: E
read the specified ServiceAccount # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_service_account(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceAccount (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ServiceAccount (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ServiceAccount
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ServiceAccount
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_service_account_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -25713,25 +32039,38 @@ def read_namespaced_service_account_with_http_info(self, name, namespace, **kwar
read the specified ServiceAccount # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_service_account_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceAccount (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the ServiceAccount (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ServiceAccount, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ServiceAccount, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -25746,7 +32085,10 @@ def read_namespaced_service_account_with_http_info(self, name, namespace, **kwar
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -25759,12 +32101,10 @@ def read_namespaced_service_account_with_http_info(self, name, namespace, **kwar
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_service_account`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_service_account`") # noqa: E501
collection_formats = {}
@@ -25776,10 +32116,10 @@ def read_namespaced_service_account_with_http_info(self, name, namespace, **kwar
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -25792,6 +32132,11 @@ def read_namespaced_service_account_with_http_info(self, name, namespace, **kwar
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ServiceAccount",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/serviceaccounts/{name}', 'GET',
path_params,
@@ -25800,13 +32145,14 @@ def read_namespaced_service_account_with_http_info(self, name, namespace, **kwar
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ServiceAccount', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_service_status(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_service_status # noqa: E501
@@ -25814,23 +32160,30 @@ def read_namespaced_service_status(self, name, namespace, **kwargs): # noqa: E5
read status of the specified Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_service_status(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Service (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Service (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Service
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Service
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_service_status_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -25841,25 +32194,38 @@ def read_namespaced_service_status_with_http_info(self, name, namespace, **kwarg
read status of the specified Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_service_status_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Service (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Service (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Service, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Service, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -25874,7 +32240,10 @@ def read_namespaced_service_status_with_http_info(self, name, namespace, **kwarg
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -25887,12 +32256,10 @@ def read_namespaced_service_status_with_http_info(self, name, namespace, **kwarg
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_service_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_service_status`") # noqa: E501
collection_formats = {}
@@ -25904,10 +32271,10 @@ def read_namespaced_service_status_with_http_info(self, name, namespace, **kwarg
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -25920,6 +32287,11 @@ def read_namespaced_service_status_with_http_info(self, name, namespace, **kwarg
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Service",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/services/{name}/status', 'GET',
path_params,
@@ -25928,13 +32300,14 @@ def read_namespaced_service_status_with_http_info(self, name, namespace, **kwarg
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Service', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_node(self, name, **kwargs): # noqa: E501
"""read_node # noqa: E501
@@ -25942,22 +32315,28 @@ def read_node(self, name, **kwargs): # noqa: E501
read the specified Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_node(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Node (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Node (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Node
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Node
"""
kwargs['_return_http_data_only'] = True
return self.read_node_with_http_info(name, **kwargs) # noqa: E501
@@ -25968,24 +32347,36 @@ def read_node_with_http_info(self, name, **kwargs): # noqa: E501
read the specified Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_node_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Node (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Node (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Node, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Node, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -25999,7 +32390,10 @@ def read_node_with_http_info(self, name, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -26012,8 +32406,7 @@ def read_node_with_http_info(self, name, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_node`") # noqa: E501
collection_formats = {}
@@ -26023,10 +32416,10 @@ def read_node_with_http_info(self, name, **kwargs): # noqa: E501
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -26039,6 +32432,11 @@ def read_node_with_http_info(self, name, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Node",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/nodes/{name}', 'GET',
path_params,
@@ -26047,13 +32445,14 @@ def read_node_with_http_info(self, name, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Node', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_node_status(self, name, **kwargs): # noqa: E501
"""read_node_status # noqa: E501
@@ -26061,22 +32460,28 @@ def read_node_status(self, name, **kwargs): # noqa: E501
read status of the specified Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_node_status(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Node (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Node (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Node
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Node
"""
kwargs['_return_http_data_only'] = True
return self.read_node_status_with_http_info(name, **kwargs) # noqa: E501
@@ -26087,24 +32492,36 @@ def read_node_status_with_http_info(self, name, **kwargs): # noqa: E501
read status of the specified Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_node_status_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Node (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Node (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Node, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Node, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -26118,7 +32535,10 @@ def read_node_status_with_http_info(self, name, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -26131,8 +32551,7 @@ def read_node_status_with_http_info(self, name, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_node_status`") # noqa: E501
collection_formats = {}
@@ -26142,10 +32561,10 @@ def read_node_status_with_http_info(self, name, **kwargs): # noqa: E501
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -26158,6 +32577,11 @@ def read_node_status_with_http_info(self, name, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Node",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/nodes/{name}/status', 'GET',
path_params,
@@ -26166,13 +32590,14 @@ def read_node_status_with_http_info(self, name, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Node', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_persistent_volume(self, name, **kwargs): # noqa: E501
"""read_persistent_volume # noqa: E501
@@ -26180,22 +32605,28 @@ def read_persistent_volume(self, name, **kwargs): # noqa: E501
read the specified PersistentVolume # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_persistent_volume(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PersistentVolume (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the PersistentVolume (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1PersistentVolume
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1PersistentVolume
"""
kwargs['_return_http_data_only'] = True
return self.read_persistent_volume_with_http_info(name, **kwargs) # noqa: E501
@@ -26206,24 +32637,36 @@ def read_persistent_volume_with_http_info(self, name, **kwargs): # noqa: E501
read the specified PersistentVolume # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_persistent_volume_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PersistentVolume (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the PersistentVolume (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1PersistentVolume, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1PersistentVolume, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -26237,7 +32680,10 @@ def read_persistent_volume_with_http_info(self, name, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -26250,8 +32696,7 @@ def read_persistent_volume_with_http_info(self, name, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_persistent_volume`") # noqa: E501
collection_formats = {}
@@ -26261,10 +32706,10 @@ def read_persistent_volume_with_http_info(self, name, **kwargs): # noqa: E501
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -26277,6 +32722,11 @@ def read_persistent_volume_with_http_info(self, name, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1PersistentVolume",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/persistentvolumes/{name}', 'GET',
path_params,
@@ -26285,13 +32735,14 @@ def read_persistent_volume_with_http_info(self, name, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1PersistentVolume', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_persistent_volume_status(self, name, **kwargs): # noqa: E501
"""read_persistent_volume_status # noqa: E501
@@ -26299,22 +32750,28 @@ def read_persistent_volume_status(self, name, **kwargs): # noqa: E501
read status of the specified PersistentVolume # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_persistent_volume_status(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PersistentVolume (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the PersistentVolume (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1PersistentVolume
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1PersistentVolume
"""
kwargs['_return_http_data_only'] = True
return self.read_persistent_volume_status_with_http_info(name, **kwargs) # noqa: E501
@@ -26325,24 +32782,36 @@ def read_persistent_volume_status_with_http_info(self, name, **kwargs): # noqa:
read status of the specified PersistentVolume # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_persistent_volume_status_with_http_info(name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PersistentVolume (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the PersistentVolume (required)
+ :type name: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1PersistentVolume, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1PersistentVolume, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -26356,7 +32825,10 @@ def read_persistent_volume_status_with_http_info(self, name, **kwargs): # noqa:
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -26369,8 +32841,7 @@ def read_persistent_volume_status_with_http_info(self, name, **kwargs): # noqa:
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_persistent_volume_status`") # noqa: E501
collection_formats = {}
@@ -26380,10 +32851,10 @@ def read_persistent_volume_status_with_http_info(self, name, **kwargs): # noqa:
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -26396,6 +32867,11 @@ def read_persistent_volume_status_with_http_info(self, name, **kwargs): # noqa:
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1PersistentVolume",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/persistentvolumes/{name}/status', 'GET',
path_params,
@@ -26404,13 +32880,14 @@ def read_persistent_volume_status_with_http_info(self, name, **kwargs): # noqa:
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1PersistentVolume', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespace(self, name, body, **kwargs): # noqa: E501
"""replace_namespace # noqa: E501
@@ -26418,26 +32895,36 @@ def replace_namespace(self, name, body, **kwargs): # noqa: E501
replace the specified Namespace # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespace(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Namespace (required)
- :param V1Namespace body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Namespace (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1Namespace
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Namespace
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Namespace
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespace_with_http_info(name, body, **kwargs) # noqa: E501
@@ -26448,28 +32935,44 @@ def replace_namespace_with_http_info(self, name, body, **kwargs): # noqa: E501
replace the specified Namespace # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespace_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Namespace (required)
- :param V1Namespace body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Namespace (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1Namespace
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Namespace, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Namespace, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -26487,7 +32990,10 @@ def replace_namespace_with_http_info(self, name, body, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -26500,12 +33006,10 @@ def replace_namespace_with_http_info(self, name, body, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespace`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespace`") # noqa: E501
collection_formats = {}
@@ -26515,16 +33019,16 @@ def replace_namespace_with_http_info(self, name, body, **kwargs): # noqa: E501
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -26539,6 +33043,12 @@ def replace_namespace_with_http_info(self, name, body, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Namespace",
+ 201: "V1Namespace",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{name}', 'PUT',
path_params,
@@ -26547,13 +33057,14 @@ def replace_namespace_with_http_info(self, name, body, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Namespace', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespace_finalize(self, name, body, **kwargs): # noqa: E501
"""replace_namespace_finalize # noqa: E501
@@ -26561,26 +33072,36 @@ def replace_namespace_finalize(self, name, body, **kwargs): # noqa: E501
replace finalize of the specified Namespace # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespace_finalize(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Namespace (required)
- :param V1Namespace body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Namespace (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1Namespace
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Namespace
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Namespace
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespace_finalize_with_http_info(name, body, **kwargs) # noqa: E501
@@ -26591,28 +33112,44 @@ def replace_namespace_finalize_with_http_info(self, name, body, **kwargs): # no
replace finalize of the specified Namespace # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespace_finalize_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Namespace (required)
- :param V1Namespace body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the Namespace (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1Namespace
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Namespace, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Namespace, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -26630,7 +33167,10 @@ def replace_namespace_finalize_with_http_info(self, name, body, **kwargs): # no
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -26643,12 +33183,10 @@ def replace_namespace_finalize_with_http_info(self, name, body, **kwargs): # no
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespace_finalize`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespace_finalize`") # noqa: E501
collection_formats = {}
@@ -26658,16 +33196,16 @@ def replace_namespace_finalize_with_http_info(self, name, body, **kwargs): # no
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -26682,6 +33220,12 @@ def replace_namespace_finalize_with_http_info(self, name, body, **kwargs): # no
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Namespace",
+ 201: "V1Namespace",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{name}/finalize', 'PUT',
path_params,
@@ -26690,13 +33234,14 @@ def replace_namespace_finalize_with_http_info(self, name, body, **kwargs): # no
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Namespace', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespace_status(self, name, body, **kwargs): # noqa: E501
"""replace_namespace_status # noqa: E501
@@ -26704,26 +33249,36 @@ def replace_namespace_status(self, name, body, **kwargs): # noqa: E501
replace status of the specified Namespace # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespace_status(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Namespace (required)
- :param V1Namespace body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Namespace (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1Namespace
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Namespace
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Namespace
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespace_status_with_http_info(name, body, **kwargs) # noqa: E501
@@ -26734,28 +33289,44 @@ def replace_namespace_status_with_http_info(self, name, body, **kwargs): # noqa
replace status of the specified Namespace # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespace_status_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Namespace (required)
- :param V1Namespace body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Namespace (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1Namespace
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Namespace, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Namespace, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -26773,7 +33344,10 @@ def replace_namespace_status_with_http_info(self, name, body, **kwargs): # noqa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -26786,12 +33360,10 @@ def replace_namespace_status_with_http_info(self, name, body, **kwargs): # noqa
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespace_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespace_status`") # noqa: E501
collection_formats = {}
@@ -26801,16 +33373,16 @@ def replace_namespace_status_with_http_info(self, name, body, **kwargs): # noqa
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -26825,6 +33397,12 @@ def replace_namespace_status_with_http_info(self, name, body, **kwargs): # noqa
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Namespace",
+ 201: "V1Namespace",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{name}/status', 'PUT',
path_params,
@@ -26833,13 +33411,14 @@ def replace_namespace_status_with_http_info(self, name, body, **kwargs): # noqa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Namespace', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_config_map(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_config_map # noqa: E501
@@ -26847,27 +33426,38 @@ def replace_namespaced_config_map(self, name, namespace, body, **kwargs): # noq
replace the specified ConfigMap # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_config_map(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ConfigMap (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ConfigMap body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ConfigMap (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ConfigMap
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ConfigMap
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ConfigMap
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_config_map_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -26878,29 +33468,46 @@ def replace_namespaced_config_map_with_http_info(self, name, namespace, body, **
replace the specified ConfigMap # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_config_map_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ConfigMap (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ConfigMap body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ConfigMap (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ConfigMap
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ConfigMap, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ConfigMap, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -26919,7 +33526,10 @@ def replace_namespaced_config_map_with_http_info(self, name, namespace, body, **
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -26932,16 +33542,13 @@ def replace_namespaced_config_map_with_http_info(self, name, namespace, body, **
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_config_map`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_config_map`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_config_map`") # noqa: E501
collection_formats = {}
@@ -26953,16 +33560,16 @@ def replace_namespaced_config_map_with_http_info(self, name, namespace, body, **
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -26977,6 +33584,12 @@ def replace_namespaced_config_map_with_http_info(self, name, namespace, body, **
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ConfigMap",
+ 201: "V1ConfigMap",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/configmaps/{name}', 'PUT',
path_params,
@@ -26985,13 +33598,14 @@ def replace_namespaced_config_map_with_http_info(self, name, namespace, body, **
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ConfigMap', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_endpoints(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_endpoints # noqa: E501
@@ -26999,27 +33613,38 @@ def replace_namespaced_endpoints(self, name, namespace, body, **kwargs): # noqa
replace the specified Endpoints # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_endpoints(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Endpoints (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Endpoints body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Endpoints (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Endpoints
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Endpoints
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Endpoints
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_endpoints_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -27030,29 +33655,46 @@ def replace_namespaced_endpoints_with_http_info(self, name, namespace, body, **k
replace the specified Endpoints # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_endpoints_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Endpoints (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Endpoints body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Endpoints (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Endpoints
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Endpoints, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Endpoints, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -27071,7 +33713,10 @@ def replace_namespaced_endpoints_with_http_info(self, name, namespace, body, **k
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -27084,16 +33729,13 @@ def replace_namespaced_endpoints_with_http_info(self, name, namespace, body, **k
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_endpoints`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_endpoints`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_endpoints`") # noqa: E501
collection_formats = {}
@@ -27105,16 +33747,16 @@ def replace_namespaced_endpoints_with_http_info(self, name, namespace, body, **k
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -27129,6 +33771,12 @@ def replace_namespaced_endpoints_with_http_info(self, name, namespace, body, **k
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Endpoints",
+ 201: "V1Endpoints",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/endpoints/{name}', 'PUT',
path_params,
@@ -27137,13 +33785,14 @@ def replace_namespaced_endpoints_with_http_info(self, name, namespace, body, **k
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Endpoints', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_event(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_event # noqa: E501
@@ -27151,27 +33800,38 @@ def replace_namespaced_event(self, name, namespace, body, **kwargs): # noqa: E5
replace the specified Event # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_event(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Event (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param CoreV1Event body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Event (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: CoreV1Event
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: CoreV1Event
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: CoreV1Event
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_event_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -27182,29 +33842,46 @@ def replace_namespaced_event_with_http_info(self, name, namespace, body, **kwarg
replace the specified Event # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_event_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Event (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param CoreV1Event body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Event (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: CoreV1Event
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(CoreV1Event, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(CoreV1Event, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -27223,7 +33900,10 @@ def replace_namespaced_event_with_http_info(self, name, namespace, body, **kwarg
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -27236,16 +33916,13 @@ def replace_namespaced_event_with_http_info(self, name, namespace, body, **kwarg
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_event`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_event`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_event`") # noqa: E501
collection_formats = {}
@@ -27257,16 +33934,16 @@ def replace_namespaced_event_with_http_info(self, name, namespace, body, **kwarg
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -27281,6 +33958,12 @@ def replace_namespaced_event_with_http_info(self, name, namespace, body, **kwarg
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "CoreV1Event",
+ 201: "CoreV1Event",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/events/{name}', 'PUT',
path_params,
@@ -27289,13 +33972,14 @@ def replace_namespaced_event_with_http_info(self, name, namespace, body, **kwarg
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='CoreV1Event', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_limit_range(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_limit_range # noqa: E501
@@ -27303,27 +33987,38 @@ def replace_namespaced_limit_range(self, name, namespace, body, **kwargs): # no
replace the specified LimitRange # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_limit_range(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the LimitRange (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1LimitRange body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the LimitRange (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1LimitRange
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1LimitRange
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1LimitRange
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_limit_range_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -27334,29 +34029,46 @@ def replace_namespaced_limit_range_with_http_info(self, name, namespace, body, *
replace the specified LimitRange # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_limit_range_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the LimitRange (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1LimitRange body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the LimitRange (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1LimitRange
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1LimitRange, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1LimitRange, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -27375,7 +34087,10 @@ def replace_namespaced_limit_range_with_http_info(self, name, namespace, body, *
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -27388,16 +34103,13 @@ def replace_namespaced_limit_range_with_http_info(self, name, namespace, body, *
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_limit_range`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_limit_range`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_limit_range`") # noqa: E501
collection_formats = {}
@@ -27409,16 +34121,16 @@ def replace_namespaced_limit_range_with_http_info(self, name, namespace, body, *
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -27433,6 +34145,12 @@ def replace_namespaced_limit_range_with_http_info(self, name, namespace, body, *
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1LimitRange",
+ 201: "V1LimitRange",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/limitranges/{name}', 'PUT',
path_params,
@@ -27441,13 +34159,14 @@ def replace_namespaced_limit_range_with_http_info(self, name, namespace, body, *
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1LimitRange', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_persistent_volume_claim(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_persistent_volume_claim # noqa: E501
@@ -27455,27 +34174,38 @@ def replace_namespaced_persistent_volume_claim(self, name, namespace, body, **kw
replace the specified PersistentVolumeClaim # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_persistent_volume_claim(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PersistentVolumeClaim (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1PersistentVolumeClaim body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the PersistentVolumeClaim (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1PersistentVolumeClaim
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1PersistentVolumeClaim
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1PersistentVolumeClaim
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_persistent_volume_claim_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -27486,29 +34216,46 @@ def replace_namespaced_persistent_volume_claim_with_http_info(self, name, namesp
replace the specified PersistentVolumeClaim # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_persistent_volume_claim_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PersistentVolumeClaim (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1PersistentVolumeClaim body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the PersistentVolumeClaim (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1PersistentVolumeClaim
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1PersistentVolumeClaim, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1PersistentVolumeClaim, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -27527,7 +34274,10 @@ def replace_namespaced_persistent_volume_claim_with_http_info(self, name, namesp
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -27540,16 +34290,13 @@ def replace_namespaced_persistent_volume_claim_with_http_info(self, name, namesp
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_persistent_volume_claim`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_persistent_volume_claim`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_persistent_volume_claim`") # noqa: E501
collection_formats = {}
@@ -27561,16 +34308,16 @@ def replace_namespaced_persistent_volume_claim_with_http_info(self, name, namesp
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -27585,6 +34332,12 @@ def replace_namespaced_persistent_volume_claim_with_http_info(self, name, namesp
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1PersistentVolumeClaim",
+ 201: "V1PersistentVolumeClaim",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/persistentvolumeclaims/{name}', 'PUT',
path_params,
@@ -27593,13 +34346,14 @@ def replace_namespaced_persistent_volume_claim_with_http_info(self, name, namesp
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1PersistentVolumeClaim', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_persistent_volume_claim_status(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_persistent_volume_claim_status # noqa: E501
@@ -27607,27 +34361,38 @@ def replace_namespaced_persistent_volume_claim_status(self, name, namespace, bod
replace status of the specified PersistentVolumeClaim # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_persistent_volume_claim_status(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PersistentVolumeClaim (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1PersistentVolumeClaim body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the PersistentVolumeClaim (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1PersistentVolumeClaim
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1PersistentVolumeClaim
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1PersistentVolumeClaim
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_persistent_volume_claim_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -27638,29 +34403,46 @@ def replace_namespaced_persistent_volume_claim_status_with_http_info(self, name,
replace status of the specified PersistentVolumeClaim # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_persistent_volume_claim_status_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PersistentVolumeClaim (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1PersistentVolumeClaim body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the PersistentVolumeClaim (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1PersistentVolumeClaim
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1PersistentVolumeClaim, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1PersistentVolumeClaim, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -27679,7 +34461,10 @@ def replace_namespaced_persistent_volume_claim_status_with_http_info(self, name,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -27692,16 +34477,13 @@ def replace_namespaced_persistent_volume_claim_status_with_http_info(self, name,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_persistent_volume_claim_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_persistent_volume_claim_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_persistent_volume_claim_status`") # noqa: E501
collection_formats = {}
@@ -27713,16 +34495,16 @@ def replace_namespaced_persistent_volume_claim_status_with_http_info(self, name,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -27737,6 +34519,12 @@ def replace_namespaced_persistent_volume_claim_status_with_http_info(self, name,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1PersistentVolumeClaim",
+ 201: "V1PersistentVolumeClaim",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/persistentvolumeclaims/{name}/status', 'PUT',
path_params,
@@ -27745,13 +34533,14 @@ def replace_namespaced_persistent_volume_claim_status_with_http_info(self, name,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1PersistentVolumeClaim', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_pod(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_pod # noqa: E501
@@ -27759,27 +34548,38 @@ def replace_namespaced_pod(self, name, namespace, body, **kwargs): # noqa: E501
replace the specified Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_pod(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Pod (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Pod body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Pod (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Pod
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Pod
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Pod
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_pod_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -27790,29 +34590,46 @@ def replace_namespaced_pod_with_http_info(self, name, namespace, body, **kwargs)
replace the specified Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_pod_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Pod (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Pod body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Pod (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Pod
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Pod, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Pod, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -27831,7 +34648,10 @@ def replace_namespaced_pod_with_http_info(self, name, namespace, body, **kwargs)
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -27844,16 +34664,13 @@ def replace_namespaced_pod_with_http_info(self, name, namespace, body, **kwargs)
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_pod`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_pod`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_pod`") # noqa: E501
collection_formats = {}
@@ -27865,16 +34682,16 @@ def replace_namespaced_pod_with_http_info(self, name, namespace, body, **kwargs)
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -27889,6 +34706,12 @@ def replace_namespaced_pod_with_http_info(self, name, namespace, body, **kwargs)
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Pod",
+ 201: "V1Pod",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}', 'PUT',
path_params,
@@ -27897,13 +34720,14 @@ def replace_namespaced_pod_with_http_info(self, name, namespace, body, **kwargs)
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Pod', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_pod_ephemeralcontainers(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_pod_ephemeralcontainers # noqa: E501
@@ -27911,27 +34735,38 @@ def replace_namespaced_pod_ephemeralcontainers(self, name, namespace, body, **kw
replace ephemeralcontainers of the specified Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_pod_ephemeralcontainers(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Pod (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Pod body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Pod (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Pod
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Pod
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Pod
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_pod_ephemeralcontainers_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -27942,29 +34777,46 @@ def replace_namespaced_pod_ephemeralcontainers_with_http_info(self, name, namesp
replace ephemeralcontainers of the specified Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_pod_ephemeralcontainers_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Pod (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Pod body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Pod (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Pod
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Pod, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Pod, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -27983,7 +34835,10 @@ def replace_namespaced_pod_ephemeralcontainers_with_http_info(self, name, namesp
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -27996,16 +34851,13 @@ def replace_namespaced_pod_ephemeralcontainers_with_http_info(self, name, namesp
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_pod_ephemeralcontainers`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_pod_ephemeralcontainers`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_pod_ephemeralcontainers`") # noqa: E501
collection_formats = {}
@@ -28017,16 +34869,16 @@ def replace_namespaced_pod_ephemeralcontainers_with_http_info(self, name, namesp
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -28041,6 +34893,12 @@ def replace_namespaced_pod_ephemeralcontainers_with_http_info(self, name, namesp
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Pod",
+ 201: "V1Pod",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/ephemeralcontainers', 'PUT',
path_params,
@@ -28049,13 +34907,14 @@ def replace_namespaced_pod_ephemeralcontainers_with_http_info(self, name, namesp
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Pod', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_pod_resize(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_pod_resize # noqa: E501
@@ -28063,27 +34922,38 @@ def replace_namespaced_pod_resize(self, name, namespace, body, **kwargs): # noq
replace resize of the specified Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_pod_resize(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Pod (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Pod body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Pod (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Pod
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Pod
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Pod
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_pod_resize_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -28094,29 +34964,46 @@ def replace_namespaced_pod_resize_with_http_info(self, name, namespace, body, **
replace resize of the specified Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_pod_resize_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Pod (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Pod body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Pod (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Pod
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Pod, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Pod, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -28135,7 +35022,10 @@ def replace_namespaced_pod_resize_with_http_info(self, name, namespace, body, **
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -28148,16 +35038,13 @@ def replace_namespaced_pod_resize_with_http_info(self, name, namespace, body, **
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_pod_resize`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_pod_resize`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_pod_resize`") # noqa: E501
collection_formats = {}
@@ -28169,16 +35056,16 @@ def replace_namespaced_pod_resize_with_http_info(self, name, namespace, body, **
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -28193,6 +35080,12 @@ def replace_namespaced_pod_resize_with_http_info(self, name, namespace, body, **
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Pod",
+ 201: "V1Pod",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/resize', 'PUT',
path_params,
@@ -28201,13 +35094,14 @@ def replace_namespaced_pod_resize_with_http_info(self, name, namespace, body, **
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Pod', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_pod_status(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_pod_status # noqa: E501
@@ -28215,27 +35109,38 @@ def replace_namespaced_pod_status(self, name, namespace, body, **kwargs): # noq
replace status of the specified Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_pod_status(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Pod (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Pod body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Pod (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Pod
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Pod
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Pod
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_pod_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -28246,29 +35151,46 @@ def replace_namespaced_pod_status_with_http_info(self, name, namespace, body, **
replace status of the specified Pod # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_pod_status_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Pod (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Pod body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Pod (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Pod
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Pod, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Pod, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -28287,7 +35209,10 @@ def replace_namespaced_pod_status_with_http_info(self, name, namespace, body, **
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -28300,16 +35225,13 @@ def replace_namespaced_pod_status_with_http_info(self, name, namespace, body, **
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_pod_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_pod_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_pod_status`") # noqa: E501
collection_formats = {}
@@ -28321,16 +35243,16 @@ def replace_namespaced_pod_status_with_http_info(self, name, namespace, body, **
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -28345,6 +35267,12 @@ def replace_namespaced_pod_status_with_http_info(self, name, namespace, body, **
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Pod",
+ 201: "V1Pod",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/pods/{name}/status', 'PUT',
path_params,
@@ -28353,13 +35281,14 @@ def replace_namespaced_pod_status_with_http_info(self, name, namespace, body, **
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Pod', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_pod_template(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_pod_template # noqa: E501
@@ -28367,27 +35296,38 @@ def replace_namespaced_pod_template(self, name, namespace, body, **kwargs): # n
replace the specified PodTemplate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_pod_template(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodTemplate (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1PodTemplate body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the PodTemplate (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1PodTemplate
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1PodTemplate
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1PodTemplate
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_pod_template_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -28398,29 +35338,46 @@ def replace_namespaced_pod_template_with_http_info(self, name, namespace, body,
replace the specified PodTemplate # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_pod_template_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PodTemplate (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1PodTemplate body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the PodTemplate (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1PodTemplate
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1PodTemplate, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1PodTemplate, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -28439,7 +35396,10 @@ def replace_namespaced_pod_template_with_http_info(self, name, namespace, body,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -28452,16 +35412,13 @@ def replace_namespaced_pod_template_with_http_info(self, name, namespace, body,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_pod_template`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_pod_template`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_pod_template`") # noqa: E501
collection_formats = {}
@@ -28473,16 +35430,16 @@ def replace_namespaced_pod_template_with_http_info(self, name, namespace, body,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -28497,6 +35454,12 @@ def replace_namespaced_pod_template_with_http_info(self, name, namespace, body,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1PodTemplate",
+ 201: "V1PodTemplate",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/podtemplates/{name}', 'PUT',
path_params,
@@ -28505,13 +35468,14 @@ def replace_namespaced_pod_template_with_http_info(self, name, namespace, body,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1PodTemplate', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_replication_controller(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_replication_controller # noqa: E501
@@ -28519,27 +35483,38 @@ def replace_namespaced_replication_controller(self, name, namespace, body, **kwa
replace the specified ReplicationController # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_replication_controller(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ReplicationController (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ReplicationController body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ReplicationController (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ReplicationController
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ReplicationController
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ReplicationController
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_replication_controller_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -28550,29 +35525,46 @@ def replace_namespaced_replication_controller_with_http_info(self, name, namespa
replace the specified ReplicationController # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_replication_controller_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ReplicationController (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ReplicationController body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ReplicationController (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ReplicationController
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ReplicationController, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ReplicationController, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -28591,7 +35583,10 @@ def replace_namespaced_replication_controller_with_http_info(self, name, namespa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -28604,16 +35599,13 @@ def replace_namespaced_replication_controller_with_http_info(self, name, namespa
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_replication_controller`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_replication_controller`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_replication_controller`") # noqa: E501
collection_formats = {}
@@ -28625,16 +35617,16 @@ def replace_namespaced_replication_controller_with_http_info(self, name, namespa
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -28649,6 +35641,12 @@ def replace_namespaced_replication_controller_with_http_info(self, name, namespa
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ReplicationController",
+ 201: "V1ReplicationController",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/replicationcontrollers/{name}', 'PUT',
path_params,
@@ -28657,13 +35655,14 @@ def replace_namespaced_replication_controller_with_http_info(self, name, namespa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ReplicationController', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_replication_controller_scale(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_replication_controller_scale # noqa: E501
@@ -28671,27 +35670,38 @@ def replace_namespaced_replication_controller_scale(self, name, namespace, body,
replace scale of the specified ReplicationController # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_replication_controller_scale(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Scale (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Scale body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Scale (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Scale
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Scale
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Scale
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_replication_controller_scale_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -28702,29 +35712,46 @@ def replace_namespaced_replication_controller_scale_with_http_info(self, name, n
replace scale of the specified ReplicationController # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_replication_controller_scale_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Scale (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Scale body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Scale (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Scale
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Scale, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Scale, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -28743,7 +35770,10 @@ def replace_namespaced_replication_controller_scale_with_http_info(self, name, n
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -28756,16 +35786,13 @@ def replace_namespaced_replication_controller_scale_with_http_info(self, name, n
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_replication_controller_scale`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_replication_controller_scale`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_replication_controller_scale`") # noqa: E501
collection_formats = {}
@@ -28777,16 +35804,16 @@ def replace_namespaced_replication_controller_scale_with_http_info(self, name, n
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -28801,6 +35828,12 @@ def replace_namespaced_replication_controller_scale_with_http_info(self, name, n
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Scale",
+ 201: "V1Scale",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/replicationcontrollers/{name}/scale', 'PUT',
path_params,
@@ -28809,13 +35842,14 @@ def replace_namespaced_replication_controller_scale_with_http_info(self, name, n
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Scale', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_replication_controller_status(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_replication_controller_status # noqa: E501
@@ -28823,27 +35857,38 @@ def replace_namespaced_replication_controller_status(self, name, namespace, body
replace status of the specified ReplicationController # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_replication_controller_status(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ReplicationController (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ReplicationController body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ReplicationController (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ReplicationController
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ReplicationController
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ReplicationController
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_replication_controller_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -28854,29 +35899,46 @@ def replace_namespaced_replication_controller_status_with_http_info(self, name,
replace status of the specified ReplicationController # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_replication_controller_status_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ReplicationController (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ReplicationController body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ReplicationController (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ReplicationController
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ReplicationController, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ReplicationController, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -28895,7 +35957,10 @@ def replace_namespaced_replication_controller_status_with_http_info(self, name,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -28908,16 +35973,13 @@ def replace_namespaced_replication_controller_status_with_http_info(self, name,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_replication_controller_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_replication_controller_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_replication_controller_status`") # noqa: E501
collection_formats = {}
@@ -28929,16 +35991,16 @@ def replace_namespaced_replication_controller_status_with_http_info(self, name,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -28953,6 +36015,12 @@ def replace_namespaced_replication_controller_status_with_http_info(self, name,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ReplicationController",
+ 201: "V1ReplicationController",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/replicationcontrollers/{name}/status', 'PUT',
path_params,
@@ -28961,13 +36029,14 @@ def replace_namespaced_replication_controller_status_with_http_info(self, name,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ReplicationController', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_resource_quota(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_resource_quota # noqa: E501
@@ -28975,27 +36044,38 @@ def replace_namespaced_resource_quota(self, name, namespace, body, **kwargs): #
replace the specified ResourceQuota # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_resource_quota(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ResourceQuota (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ResourceQuota body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ResourceQuota (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ResourceQuota
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ResourceQuota
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ResourceQuota
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_resource_quota_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -29006,29 +36086,46 @@ def replace_namespaced_resource_quota_with_http_info(self, name, namespace, body
replace the specified ResourceQuota # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_resource_quota_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ResourceQuota (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ResourceQuota body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ResourceQuota (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ResourceQuota
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ResourceQuota, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ResourceQuota, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -29047,7 +36144,10 @@ def replace_namespaced_resource_quota_with_http_info(self, name, namespace, body
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -29060,16 +36160,13 @@ def replace_namespaced_resource_quota_with_http_info(self, name, namespace, body
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_resource_quota`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_resource_quota`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_resource_quota`") # noqa: E501
collection_formats = {}
@@ -29081,16 +36178,16 @@ def replace_namespaced_resource_quota_with_http_info(self, name, namespace, body
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -29105,6 +36202,12 @@ def replace_namespaced_resource_quota_with_http_info(self, name, namespace, body
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ResourceQuota",
+ 201: "V1ResourceQuota",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/resourcequotas/{name}', 'PUT',
path_params,
@@ -29113,13 +36216,14 @@ def replace_namespaced_resource_quota_with_http_info(self, name, namespace, body
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ResourceQuota', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_resource_quota_status(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_resource_quota_status # noqa: E501
@@ -29127,27 +36231,38 @@ def replace_namespaced_resource_quota_status(self, name, namespace, body, **kwar
replace status of the specified ResourceQuota # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_resource_quota_status(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ResourceQuota (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ResourceQuota body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ResourceQuota (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ResourceQuota
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ResourceQuota
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ResourceQuota
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_resource_quota_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -29158,29 +36273,46 @@ def replace_namespaced_resource_quota_status_with_http_info(self, name, namespac
replace status of the specified ResourceQuota # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_resource_quota_status_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ResourceQuota (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ResourceQuota body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ResourceQuota (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ResourceQuota
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ResourceQuota, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ResourceQuota, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -29199,7 +36331,10 @@ def replace_namespaced_resource_quota_status_with_http_info(self, name, namespac
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -29212,16 +36347,13 @@ def replace_namespaced_resource_quota_status_with_http_info(self, name, namespac
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_resource_quota_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_resource_quota_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_resource_quota_status`") # noqa: E501
collection_formats = {}
@@ -29233,16 +36365,16 @@ def replace_namespaced_resource_quota_status_with_http_info(self, name, namespac
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -29257,6 +36389,12 @@ def replace_namespaced_resource_quota_status_with_http_info(self, name, namespac
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ResourceQuota",
+ 201: "V1ResourceQuota",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/resourcequotas/{name}/status', 'PUT',
path_params,
@@ -29265,13 +36403,14 @@ def replace_namespaced_resource_quota_status_with_http_info(self, name, namespac
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ResourceQuota', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_secret(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_secret # noqa: E501
@@ -29279,27 +36418,38 @@ def replace_namespaced_secret(self, name, namespace, body, **kwargs): # noqa: E
replace the specified Secret # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_secret(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Secret (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Secret body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Secret (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Secret
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Secret
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Secret
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_secret_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -29310,29 +36460,46 @@ def replace_namespaced_secret_with_http_info(self, name, namespace, body, **kwar
replace the specified Secret # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_secret_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Secret (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Secret body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Secret (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Secret
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Secret, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Secret, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -29351,7 +36518,10 @@ def replace_namespaced_secret_with_http_info(self, name, namespace, body, **kwar
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -29364,16 +36534,13 @@ def replace_namespaced_secret_with_http_info(self, name, namespace, body, **kwar
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_secret`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_secret`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_secret`") # noqa: E501
collection_formats = {}
@@ -29385,16 +36552,16 @@ def replace_namespaced_secret_with_http_info(self, name, namespace, body, **kwar
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -29409,6 +36576,12 @@ def replace_namespaced_secret_with_http_info(self, name, namespace, body, **kwar
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Secret",
+ 201: "V1Secret",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/secrets/{name}', 'PUT',
path_params,
@@ -29417,13 +36590,14 @@ def replace_namespaced_secret_with_http_info(self, name, namespace, body, **kwar
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Secret', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_service(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_service # noqa: E501
@@ -29431,27 +36605,38 @@ def replace_namespaced_service(self, name, namespace, body, **kwargs): # noqa:
replace the specified Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_service(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Service (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Service body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Service (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Service
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Service
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Service
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_service_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -29462,29 +36647,46 @@ def replace_namespaced_service_with_http_info(self, name, namespace, body, **kwa
replace the specified Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_service_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Service (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Service body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Service (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Service
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Service, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Service, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -29503,7 +36705,10 @@ def replace_namespaced_service_with_http_info(self, name, namespace, body, **kwa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -29516,16 +36721,13 @@ def replace_namespaced_service_with_http_info(self, name, namespace, body, **kwa
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_service`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_service`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_service`") # noqa: E501
collection_formats = {}
@@ -29537,16 +36739,16 @@ def replace_namespaced_service_with_http_info(self, name, namespace, body, **kwa
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -29561,6 +36763,12 @@ def replace_namespaced_service_with_http_info(self, name, namespace, body, **kwa
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Service",
+ 201: "V1Service",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/services/{name}', 'PUT',
path_params,
@@ -29569,13 +36777,14 @@ def replace_namespaced_service_with_http_info(self, name, namespace, body, **kwa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Service', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_service_account(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_service_account # noqa: E501
@@ -29583,27 +36792,38 @@ def replace_namespaced_service_account(self, name, namespace, body, **kwargs):
replace the specified ServiceAccount # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_service_account(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceAccount (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ServiceAccount body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ServiceAccount (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ServiceAccount
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1ServiceAccount
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1ServiceAccount
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_service_account_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -29614,29 +36834,46 @@ def replace_namespaced_service_account_with_http_info(self, name, namespace, bod
replace the specified ServiceAccount # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_service_account_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the ServiceAccount (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1ServiceAccount body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the ServiceAccount (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1ServiceAccount
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1ServiceAccount, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1ServiceAccount, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -29655,7 +36892,10 @@ def replace_namespaced_service_account_with_http_info(self, name, namespace, bod
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -29668,16 +36908,13 @@ def replace_namespaced_service_account_with_http_info(self, name, namespace, bod
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_service_account`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_service_account`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_service_account`") # noqa: E501
collection_formats = {}
@@ -29689,16 +36926,16 @@ def replace_namespaced_service_account_with_http_info(self, name, namespace, bod
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -29713,6 +36950,12 @@ def replace_namespaced_service_account_with_http_info(self, name, namespace, bod
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1ServiceAccount",
+ 201: "V1ServiceAccount",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/serviceaccounts/{name}', 'PUT',
path_params,
@@ -29721,13 +36964,14 @@ def replace_namespaced_service_account_with_http_info(self, name, namespace, bod
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1ServiceAccount', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_service_status(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_service_status # noqa: E501
@@ -29735,27 +36979,38 @@ def replace_namespaced_service_status(self, name, namespace, body, **kwargs): #
replace status of the specified Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_service_status(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Service (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Service body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Service (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Service
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Service
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Service
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_service_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -29766,29 +37021,46 @@ def replace_namespaced_service_status_with_http_info(self, name, namespace, body
replace status of the specified Service # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_service_status_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Service (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1Service body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Service (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1Service
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Service, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Service, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -29807,7 +37079,10 @@ def replace_namespaced_service_status_with_http_info(self, name, namespace, body
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -29820,16 +37095,13 @@ def replace_namespaced_service_status_with_http_info(self, name, namespace, body
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_service_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_service_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_service_status`") # noqa: E501
collection_formats = {}
@@ -29841,16 +37113,16 @@ def replace_namespaced_service_status_with_http_info(self, name, namespace, body
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -29865,6 +37137,12 @@ def replace_namespaced_service_status_with_http_info(self, name, namespace, body
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Service",
+ 201: "V1Service",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/namespaces/{namespace}/services/{name}/status', 'PUT',
path_params,
@@ -29873,13 +37151,14 @@ def replace_namespaced_service_status_with_http_info(self, name, namespace, body
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Service', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_node(self, name, body, **kwargs): # noqa: E501
"""replace_node # noqa: E501
@@ -29887,26 +37166,36 @@ def replace_node(self, name, body, **kwargs): # noqa: E501
replace the specified Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_node(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Node (required)
- :param V1Node body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Node (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1Node
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Node
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Node
"""
kwargs['_return_http_data_only'] = True
return self.replace_node_with_http_info(name, body, **kwargs) # noqa: E501
@@ -29917,28 +37206,44 @@ def replace_node_with_http_info(self, name, body, **kwargs): # noqa: E501
replace the specified Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_node_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Node (required)
- :param V1Node body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Node (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1Node
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Node, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Node, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -29956,7 +37261,10 @@ def replace_node_with_http_info(self, name, body, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -29969,12 +37277,10 @@ def replace_node_with_http_info(self, name, body, **kwargs): # noqa: E501
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_node`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_node`") # noqa: E501
collection_formats = {}
@@ -29984,16 +37290,16 @@ def replace_node_with_http_info(self, name, body, **kwargs): # noqa: E501
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -30008,6 +37314,12 @@ def replace_node_with_http_info(self, name, body, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Node",
+ 201: "V1Node",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/nodes/{name}', 'PUT',
path_params,
@@ -30016,13 +37328,14 @@ def replace_node_with_http_info(self, name, body, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Node', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_node_status(self, name, body, **kwargs): # noqa: E501
"""replace_node_status # noqa: E501
@@ -30030,26 +37343,36 @@ def replace_node_status(self, name, body, **kwargs): # noqa: E501
replace status of the specified Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_node_status(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Node (required)
- :param V1Node body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Node (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1Node
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Node
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Node
"""
kwargs['_return_http_data_only'] = True
return self.replace_node_status_with_http_info(name, body, **kwargs) # noqa: E501
@@ -30060,28 +37383,44 @@ def replace_node_status_with_http_info(self, name, body, **kwargs): # noqa: E50
replace status of the specified Node # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_node_status_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the Node (required)
- :param V1Node body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the Node (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1Node
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Node, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Node, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -30099,7 +37438,10 @@ def replace_node_status_with_http_info(self, name, body, **kwargs): # noqa: E50
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -30112,12 +37454,10 @@ def replace_node_status_with_http_info(self, name, body, **kwargs): # noqa: E50
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_node_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_node_status`") # noqa: E501
collection_formats = {}
@@ -30127,16 +37467,16 @@ def replace_node_status_with_http_info(self, name, body, **kwargs): # noqa: E50
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -30151,6 +37491,12 @@ def replace_node_status_with_http_info(self, name, body, **kwargs): # noqa: E50
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Node",
+ 201: "V1Node",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/nodes/{name}/status', 'PUT',
path_params,
@@ -30159,13 +37505,14 @@ def replace_node_status_with_http_info(self, name, body, **kwargs): # noqa: E50
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Node', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_persistent_volume(self, name, body, **kwargs): # noqa: E501
"""replace_persistent_volume # noqa: E501
@@ -30173,26 +37520,36 @@ def replace_persistent_volume(self, name, body, **kwargs): # noqa: E501
replace the specified PersistentVolume # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_persistent_volume(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PersistentVolume (required)
- :param V1PersistentVolume body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the PersistentVolume (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1PersistentVolume
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1PersistentVolume
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1PersistentVolume
"""
kwargs['_return_http_data_only'] = True
return self.replace_persistent_volume_with_http_info(name, body, **kwargs) # noqa: E501
@@ -30203,28 +37560,44 @@ def replace_persistent_volume_with_http_info(self, name, body, **kwargs): # noq
replace the specified PersistentVolume # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_persistent_volume_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PersistentVolume (required)
- :param V1PersistentVolume body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the PersistentVolume (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1PersistentVolume
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1PersistentVolume, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1PersistentVolume, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -30242,7 +37615,10 @@ def replace_persistent_volume_with_http_info(self, name, body, **kwargs): # noq
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -30255,12 +37631,10 @@ def replace_persistent_volume_with_http_info(self, name, body, **kwargs): # noq
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_persistent_volume`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_persistent_volume`") # noqa: E501
collection_formats = {}
@@ -30270,16 +37644,16 @@ def replace_persistent_volume_with_http_info(self, name, body, **kwargs): # noq
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -30294,6 +37668,12 @@ def replace_persistent_volume_with_http_info(self, name, body, **kwargs): # noq
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1PersistentVolume",
+ 201: "V1PersistentVolume",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/persistentvolumes/{name}', 'PUT',
path_params,
@@ -30302,13 +37682,14 @@ def replace_persistent_volume_with_http_info(self, name, body, **kwargs): # noq
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1PersistentVolume', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_persistent_volume_status(self, name, body, **kwargs): # noqa: E501
"""replace_persistent_volume_status # noqa: E501
@@ -30316,26 +37697,36 @@ def replace_persistent_volume_status(self, name, body, **kwargs): # noqa: E501
replace status of the specified PersistentVolume # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_persistent_volume_status(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PersistentVolume (required)
- :param V1PersistentVolume body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the PersistentVolume (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1PersistentVolume
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1PersistentVolume
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1PersistentVolume
"""
kwargs['_return_http_data_only'] = True
return self.replace_persistent_volume_status_with_http_info(name, body, **kwargs) # noqa: E501
@@ -30346,28 +37737,44 @@ def replace_persistent_volume_status_with_http_info(self, name, body, **kwargs):
replace status of the specified PersistentVolume # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_persistent_volume_status_with_http_info(name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the PersistentVolume (required)
- :param V1PersistentVolume body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the PersistentVolume (required)
+ :type name: str
+ :param body: (required)
+ :type body: V1PersistentVolume
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1PersistentVolume, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1PersistentVolume, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -30385,7 +37792,10 @@ def replace_persistent_volume_status_with_http_info(self, name, body, **kwargs):
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -30398,12 +37808,10 @@ def replace_persistent_volume_status_with_http_info(self, name, body, **kwargs):
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_persistent_volume_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_persistent_volume_status`") # noqa: E501
collection_formats = {}
@@ -30413,16 +37821,16 @@ def replace_persistent_volume_status_with_http_info(self, name, body, **kwargs):
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -30437,6 +37845,12 @@ def replace_persistent_volume_status_with_http_info(self, name, body, **kwargs):
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1PersistentVolume",
+ 201: "V1PersistentVolume",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/api/v1/persistentvolumes/{name}/status', 'PUT',
path_params,
@@ -30445,10 +37859,11 @@ def replace_persistent_volume_status_with_http_info(self, name, body, **kwargs):
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1PersistentVolume', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/custom_objects_api.py b/kubernetes/client/api/custom_objects_api.py
index 23de498104..a12f7b6155 100644
--- a/kubernetes/client/api/custom_objects_api.py
+++ b/kubernetes/client/api/custom_objects_api.py
@@ -42,28 +42,40 @@ def create_cluster_custom_object(self, group, version, plural, body, **kwargs):
Creates a cluster scoped Custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_cluster_custom_object(group, version, plural, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: The custom resource's group name (required)
- :param str version: The custom resource's version (required)
- :param str plural: The custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param object body: The JSON schema of the Resource to create. (required)
- :param str pretty: If 'true', then the output is pretty printed.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :param group: The custom resource's group name (required)
+ :type group: str
+ :param version: The custom resource's version (required)
+ :type version: str
+ :param plural: The custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param body: The JSON schema of the Resource to create. (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed.
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: object
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: object
"""
kwargs['_return_http_data_only'] = True
return self.create_cluster_custom_object_with_http_info(group, version, plural, body, **kwargs) # noqa: E501
@@ -74,30 +86,48 @@ def create_cluster_custom_object_with_http_info(self, group, version, plural, bo
Creates a cluster scoped Custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_cluster_custom_object_with_http_info(group, version, plural, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: The custom resource's group name (required)
- :param str version: The custom resource's version (required)
- :param str plural: The custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param object body: The JSON schema of the Resource to create. (required)
- :param str pretty: If 'true', then the output is pretty printed.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :param group: The custom resource's group name (required)
+ :type group: str
+ :param version: The custom resource's version (required)
+ :type version: str
+ :param plural: The custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param body: The JSON schema of the Resource to create. (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed.
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(object, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -117,7 +147,10 @@ def create_cluster_custom_object_with_http_info(self, group, version, plural, bo
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -130,20 +163,16 @@ def create_cluster_custom_object_with_http_info(self, group, version, plural, bo
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'group' is set
- if self.api_client.client_side_validation and ('group' not in local_var_params or # noqa: E501
- local_var_params['group'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('group') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `group` when calling `create_cluster_custom_object`") # noqa: E501
# verify the required parameter 'version' is set
- if self.api_client.client_side_validation and ('version' not in local_var_params or # noqa: E501
- local_var_params['version'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('version') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `version` when calling `create_cluster_custom_object`") # noqa: E501
# verify the required parameter 'plural' is set
- if self.api_client.client_side_validation and ('plural' not in local_var_params or # noqa: E501
- local_var_params['plural'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('plural') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `plural` when calling `create_cluster_custom_object`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_cluster_custom_object`") # noqa: E501
collection_formats = {}
@@ -157,16 +186,16 @@ def create_cluster_custom_object_with_http_info(self, group, version, plural, bo
path_params['plural'] = local_var_params['plural'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -181,6 +210,11 @@ def create_cluster_custom_object_with_http_info(self, group, version, plural, bo
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 201: "object",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/{group}/{version}/{plural}', 'POST',
path_params,
@@ -189,13 +223,14 @@ def create_cluster_custom_object_with_http_info(self, group, version, plural, bo
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='object', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def create_namespaced_custom_object(self, group, version, namespace, plural, body, **kwargs): # noqa: E501
"""create_namespaced_custom_object # noqa: E501
@@ -203,29 +238,42 @@ def create_namespaced_custom_object(self, group, version, namespace, plural, bod
Creates a namespace scoped Custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_custom_object(group, version, namespace, plural, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: The custom resource's group name (required)
- :param str version: The custom resource's version (required)
- :param str namespace: The custom resource's namespace (required)
- :param str plural: The custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param object body: The JSON schema of the Resource to create. (required)
- :param str pretty: If 'true', then the output is pretty printed.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :param group: The custom resource's group name (required)
+ :type group: str
+ :param version: The custom resource's version (required)
+ :type version: str
+ :param namespace: The custom resource's namespace (required)
+ :type namespace: str
+ :param plural: The custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param body: The JSON schema of the Resource to create. (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed.
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: object
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: object
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_custom_object_with_http_info(group, version, namespace, plural, body, **kwargs) # noqa: E501
@@ -236,31 +284,50 @@ def create_namespaced_custom_object_with_http_info(self, group, version, namespa
Creates a namespace scoped Custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_custom_object_with_http_info(group, version, namespace, plural, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: The custom resource's group name (required)
- :param str version: The custom resource's version (required)
- :param str namespace: The custom resource's namespace (required)
- :param str plural: The custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param object body: The JSON schema of the Resource to create. (required)
- :param str pretty: If 'true', then the output is pretty printed.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :param group: The custom resource's group name (required)
+ :type group: str
+ :param version: The custom resource's version (required)
+ :type version: str
+ :param namespace: The custom resource's namespace (required)
+ :type namespace: str
+ :param plural: The custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param body: The JSON schema of the Resource to create. (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed.
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(object, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -281,7 +348,10 @@ def create_namespaced_custom_object_with_http_info(self, group, version, namespa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -294,24 +364,19 @@ def create_namespaced_custom_object_with_http_info(self, group, version, namespa
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'group' is set
- if self.api_client.client_side_validation and ('group' not in local_var_params or # noqa: E501
- local_var_params['group'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('group') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `group` when calling `create_namespaced_custom_object`") # noqa: E501
# verify the required parameter 'version' is set
- if self.api_client.client_side_validation and ('version' not in local_var_params or # noqa: E501
- local_var_params['version'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('version') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `version` when calling `create_namespaced_custom_object`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_custom_object`") # noqa: E501
# verify the required parameter 'plural' is set
- if self.api_client.client_side_validation and ('plural' not in local_var_params or # noqa: E501
- local_var_params['plural'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('plural') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `plural` when calling `create_namespaced_custom_object`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_custom_object`") # noqa: E501
collection_formats = {}
@@ -327,16 +392,16 @@ def create_namespaced_custom_object_with_http_info(self, group, version, namespa
path_params['plural'] = local_var_params['plural'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -351,6 +416,11 @@ def create_namespaced_custom_object_with_http_info(self, group, version, namespa
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 201: "object",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/{group}/{version}/namespaces/{namespace}/{plural}', 'POST',
path_params,
@@ -359,13 +429,14 @@ def create_namespaced_custom_object_with_http_info(self, group, version, namespa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='object', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_cluster_custom_object(self, group, version, plural, name, **kwargs): # noqa: E501
"""delete_cluster_custom_object # noqa: E501
@@ -373,29 +444,42 @@ def delete_cluster_custom_object(self, group, version, plural, name, **kwargs):
Deletes the specified cluster scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_cluster_custom_object(group, version, plural, name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str plural: the custom object's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param V1DeleteOptions body:
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param plural: the custom object's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.
+ :type propagation_policy: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: object
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: object
"""
kwargs['_return_http_data_only'] = True
return self.delete_cluster_custom_object_with_http_info(group, version, plural, name, **kwargs) # noqa: E501
@@ -406,31 +490,50 @@ def delete_cluster_custom_object_with_http_info(self, group, version, plural, na
Deletes the specified cluster scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_cluster_custom_object_with_http_info(group, version, plural, name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str plural: the custom object's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param V1DeleteOptions body:
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param plural: the custom object's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.
+ :type propagation_policy: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(object, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -451,7 +554,10 @@ def delete_cluster_custom_object_with_http_info(self, group, version, plural, na
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -464,20 +570,16 @@ def delete_cluster_custom_object_with_http_info(self, group, version, plural, na
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'group' is set
- if self.api_client.client_side_validation and ('group' not in local_var_params or # noqa: E501
- local_var_params['group'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('group') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `group` when calling `delete_cluster_custom_object`") # noqa: E501
# verify the required parameter 'version' is set
- if self.api_client.client_side_validation and ('version' not in local_var_params or # noqa: E501
- local_var_params['version'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('version') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `version` when calling `delete_cluster_custom_object`") # noqa: E501
# verify the required parameter 'plural' is set
- if self.api_client.client_side_validation and ('plural' not in local_var_params or # noqa: E501
- local_var_params['plural'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('plural') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `plural` when calling `delete_cluster_custom_object`") # noqa: E501
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_cluster_custom_object`") # noqa: E501
collection_formats = {}
@@ -493,16 +595,16 @@ def delete_cluster_custom_object_with_http_info(self, group, version, plural, na
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -517,6 +619,11 @@ def delete_cluster_custom_object_with_http_info(self, group, version, plural, na
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "object",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/{group}/{version}/{plural}/{name}', 'DELETE',
path_params,
@@ -525,13 +632,14 @@ def delete_cluster_custom_object_with_http_info(self, group, version, plural, na
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='object', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_cluster_custom_object(self, group, version, plural, **kwargs): # noqa: E501
"""delete_collection_cluster_custom_object # noqa: E501
@@ -539,30 +647,44 @@ def delete_collection_cluster_custom_object(self, group, version, plural, **kwar
Delete collection of cluster scoped custom objects # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_cluster_custom_object(group, version, plural, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: The custom resource's group name (required)
- :param str version: The custom resource's version (required)
- :param str plural: The custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str pretty: If 'true', then the output is pretty printed.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param V1DeleteOptions body:
+ :param group: The custom resource's group name (required)
+ :type group: str
+ :param version: The custom resource's version (required)
+ :type version: str
+ :param plural: The custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param pretty: If 'true', then the output is pretty printed.
+ :type pretty: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.
+ :type propagation_policy: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: object
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: object
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_cluster_custom_object_with_http_info(group, version, plural, **kwargs) # noqa: E501
@@ -573,32 +695,52 @@ def delete_collection_cluster_custom_object_with_http_info(self, group, version,
Delete collection of cluster scoped custom objects # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_cluster_custom_object_with_http_info(group, version, plural, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: The custom resource's group name (required)
- :param str version: The custom resource's version (required)
- :param str plural: The custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str pretty: If 'true', then the output is pretty printed.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param V1DeleteOptions body:
+ :param group: The custom resource's group name (required)
+ :type group: str
+ :param version: The custom resource's version (required)
+ :type version: str
+ :param plural: The custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param pretty: If 'true', then the output is pretty printed.
+ :type pretty: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.
+ :type propagation_policy: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(object, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -620,7 +762,10 @@ def delete_collection_cluster_custom_object_with_http_info(self, group, version,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -633,16 +778,13 @@ def delete_collection_cluster_custom_object_with_http_info(self, group, version,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'group' is set
- if self.api_client.client_side_validation and ('group' not in local_var_params or # noqa: E501
- local_var_params['group'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('group') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `group` when calling `delete_collection_cluster_custom_object`") # noqa: E501
# verify the required parameter 'version' is set
- if self.api_client.client_side_validation and ('version' not in local_var_params or # noqa: E501
- local_var_params['version'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('version') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `version` when calling `delete_collection_cluster_custom_object`") # noqa: E501
# verify the required parameter 'plural' is set
- if self.api_client.client_side_validation and ('plural' not in local_var_params or # noqa: E501
- local_var_params['plural'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('plural') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `plural` when calling `delete_collection_cluster_custom_object`") # noqa: E501
collection_formats = {}
@@ -656,20 +798,20 @@ def delete_collection_cluster_custom_object_with_http_info(self, group, version,
path_params['plural'] = local_var_params['plural'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -684,6 +826,11 @@ def delete_collection_cluster_custom_object_with_http_info(self, group, version,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "object",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/{group}/{version}/{plural}', 'DELETE',
path_params,
@@ -692,13 +839,14 @@ def delete_collection_cluster_custom_object_with_http_info(self, group, version,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='object', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_namespaced_custom_object(self, group, version, namespace, plural, **kwargs): # noqa: E501
"""delete_collection_namespaced_custom_object # noqa: E501
@@ -706,32 +854,48 @@ def delete_collection_namespaced_custom_object(self, group, version, namespace,
Delete collection of namespace scoped custom objects # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_custom_object(group, version, namespace, plural, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: The custom resource's group name (required)
- :param str version: The custom resource's version (required)
- :param str namespace: The custom resource's namespace (required)
- :param str plural: The custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str pretty: If 'true', then the output is pretty printed.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param V1DeleteOptions body:
+ :param group: The custom resource's group name (required)
+ :type group: str
+ :param version: The custom resource's version (required)
+ :type version: str
+ :param namespace: The custom resource's namespace (required)
+ :type namespace: str
+ :param plural: The custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param pretty: If 'true', then the output is pretty printed.
+ :type pretty: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.
+ :type propagation_policy: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: object
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: object
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_namespaced_custom_object_with_http_info(group, version, namespace, plural, **kwargs) # noqa: E501
@@ -742,34 +906,56 @@ def delete_collection_namespaced_custom_object_with_http_info(self, group, versi
Delete collection of namespace scoped custom objects # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_custom_object_with_http_info(group, version, namespace, plural, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: The custom resource's group name (required)
- :param str version: The custom resource's version (required)
- :param str namespace: The custom resource's namespace (required)
- :param str plural: The custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str pretty: If 'true', then the output is pretty printed.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param V1DeleteOptions body:
+ :param group: The custom resource's group name (required)
+ :type group: str
+ :param version: The custom resource's version (required)
+ :type version: str
+ :param namespace: The custom resource's namespace (required)
+ :type namespace: str
+ :param plural: The custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param pretty: If 'true', then the output is pretty printed.
+ :type pretty: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.
+ :type propagation_policy: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(object, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -793,7 +979,10 @@ def delete_collection_namespaced_custom_object_with_http_info(self, group, versi
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -806,20 +995,16 @@ def delete_collection_namespaced_custom_object_with_http_info(self, group, versi
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'group' is set
- if self.api_client.client_side_validation and ('group' not in local_var_params or # noqa: E501
- local_var_params['group'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('group') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `group` when calling `delete_collection_namespaced_custom_object`") # noqa: E501
# verify the required parameter 'version' is set
- if self.api_client.client_side_validation and ('version' not in local_var_params or # noqa: E501
- local_var_params['version'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('version') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `version` when calling `delete_collection_namespaced_custom_object`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_custom_object`") # noqa: E501
# verify the required parameter 'plural' is set
- if self.api_client.client_side_validation and ('plural' not in local_var_params or # noqa: E501
- local_var_params['plural'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('plural') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `plural` when calling `delete_collection_namespaced_custom_object`") # noqa: E501
collection_formats = {}
@@ -835,22 +1020,22 @@ def delete_collection_namespaced_custom_object_with_http_info(self, group, versi
path_params['plural'] = local_var_params['plural'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -865,6 +1050,11 @@ def delete_collection_namespaced_custom_object_with_http_info(self, group, versi
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "object",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/{group}/{version}/namespaces/{namespace}/{plural}', 'DELETE',
path_params,
@@ -873,13 +1063,14 @@ def delete_collection_namespaced_custom_object_with_http_info(self, group, versi
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='object', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_namespaced_custom_object(self, group, version, namespace, plural, name, **kwargs): # noqa: E501
"""delete_namespaced_custom_object # noqa: E501
@@ -887,30 +1078,44 @@ def delete_namespaced_custom_object(self, group, version, namespace, plural, nam
Deletes the specified namespace scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_custom_object(group, version, namespace, plural, name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str namespace: The custom resource's namespace (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param V1DeleteOptions body:
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param namespace: The custom resource's namespace (required)
+ :type namespace: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.
+ :type propagation_policy: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: object
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: object
"""
kwargs['_return_http_data_only'] = True
return self.delete_namespaced_custom_object_with_http_info(group, version, namespace, plural, name, **kwargs) # noqa: E501
@@ -921,32 +1126,52 @@ def delete_namespaced_custom_object_with_http_info(self, group, version, namespa
Deletes the specified namespace scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_custom_object_with_http_info(group, version, namespace, plural, name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str namespace: The custom resource's namespace (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param V1DeleteOptions body:
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param namespace: The custom resource's namespace (required)
+ :type namespace: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.
+ :type propagation_policy: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(object, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -968,7 +1193,10 @@ def delete_namespaced_custom_object_with_http_info(self, group, version, namespa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -981,24 +1209,19 @@ def delete_namespaced_custom_object_with_http_info(self, group, version, namespa
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'group' is set
- if self.api_client.client_side_validation and ('group' not in local_var_params or # noqa: E501
- local_var_params['group'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('group') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `group` when calling `delete_namespaced_custom_object`") # noqa: E501
# verify the required parameter 'version' is set
- if self.api_client.client_side_validation and ('version' not in local_var_params or # noqa: E501
- local_var_params['version'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('version') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `version` when calling `delete_namespaced_custom_object`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_custom_object`") # noqa: E501
# verify the required parameter 'plural' is set
- if self.api_client.client_side_validation and ('plural' not in local_var_params or # noqa: E501
- local_var_params['plural'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('plural') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `plural` when calling `delete_namespaced_custom_object`") # noqa: E501
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_custom_object`") # noqa: E501
collection_formats = {}
@@ -1016,16 +1239,16 @@ def delete_namespaced_custom_object_with_http_info(self, group, version, namespa
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1040,6 +1263,11 @@ def delete_namespaced_custom_object_with_http_info(self, group, version, namespa
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "object",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/{group}/{version}/namespaces/{namespace}/{plural}/{name}', 'DELETE',
path_params,
@@ -1048,13 +1276,14 @@ def delete_namespaced_custom_object_with_http_info(self, group, version, namespa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='object', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def get_api_resources(self, group, version, **kwargs): # noqa: E501
"""get_api_resources # noqa: E501
@@ -1062,22 +1291,28 @@ def get_api_resources(self, group, version, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources(group, version, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: The custom resource's group name (required)
- :param str version: The custom resource's version (required)
+ :param group: The custom resource's group name (required)
+ :type group: str
+ :param version: The custom resource's version (required)
+ :type version: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIResourceList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIResourceList
"""
kwargs['_return_http_data_only'] = True
return self.get_api_resources_with_http_info(group, version, **kwargs) # noqa: E501
@@ -1088,24 +1323,36 @@ def get_api_resources_with_http_info(self, group, version, **kwargs): # noqa: E
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources_with_http_info(group, version, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: The custom resource's group name (required)
- :param str version: The custom resource's version (required)
+ :param group: The custom resource's group name (required)
+ :type group: str
+ :param version: The custom resource's version (required)
+ :type version: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1119,7 +1366,10 @@ def get_api_resources_with_http_info(self, group, version, **kwargs): # noqa: E
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1132,12 +1382,10 @@ def get_api_resources_with_http_info(self, group, version, **kwargs): # noqa: E
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'group' is set
- if self.api_client.client_side_validation and ('group' not in local_var_params or # noqa: E501
- local_var_params['group'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('group') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `group` when calling `get_api_resources`") # noqa: E501
# verify the required parameter 'version' is set
- if self.api_client.client_side_validation and ('version' not in local_var_params or # noqa: E501
- local_var_params['version'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('version') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `version` when calling `get_api_resources`") # noqa: E501
collection_formats = {}
@@ -1150,7 +1398,7 @@ def get_api_resources_with_http_info(self, group, version, **kwargs): # noqa: E
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1163,6 +1411,11 @@ def get_api_resources_with_http_info(self, group, version, **kwargs): # noqa: E
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIResourceList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/{group}/{version}', 'GET',
path_params,
@@ -1171,13 +1424,14 @@ def get_api_resources_with_http_info(self, group, version, **kwargs): # noqa: E
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIResourceList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def get_cluster_custom_object(self, group, version, plural, name, **kwargs): # noqa: E501
"""get_cluster_custom_object # noqa: E501
@@ -1185,24 +1439,32 @@ def get_cluster_custom_object(self, group, version, plural, name, **kwargs): #
Returns a cluster scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_cluster_custom_object(group, version, plural, name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str plural: the custom object's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param plural: the custom object's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: object
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: object
"""
kwargs['_return_http_data_only'] = True
return self.get_cluster_custom_object_with_http_info(group, version, plural, name, **kwargs) # noqa: E501
@@ -1213,26 +1475,40 @@ def get_cluster_custom_object_with_http_info(self, group, version, plural, name,
Returns a cluster scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_cluster_custom_object_with_http_info(group, version, plural, name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str plural: the custom object's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param plural: the custom object's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(object, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1248,7 +1524,10 @@ def get_cluster_custom_object_with_http_info(self, group, version, plural, name,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1261,20 +1540,16 @@ def get_cluster_custom_object_with_http_info(self, group, version, plural, name,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'group' is set
- if self.api_client.client_side_validation and ('group' not in local_var_params or # noqa: E501
- local_var_params['group'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('group') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `group` when calling `get_cluster_custom_object`") # noqa: E501
# verify the required parameter 'version' is set
- if self.api_client.client_side_validation and ('version' not in local_var_params or # noqa: E501
- local_var_params['version'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('version') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `version` when calling `get_cluster_custom_object`") # noqa: E501
# verify the required parameter 'plural' is set
- if self.api_client.client_side_validation and ('plural' not in local_var_params or # noqa: E501
- local_var_params['plural'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('plural') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `plural` when calling `get_cluster_custom_object`") # noqa: E501
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `get_cluster_custom_object`") # noqa: E501
collection_formats = {}
@@ -1291,7 +1566,7 @@ def get_cluster_custom_object_with_http_info(self, group, version, plural, name,
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1304,6 +1579,11 @@ def get_cluster_custom_object_with_http_info(self, group, version, plural, name,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "object",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/{group}/{version}/{plural}/{name}', 'GET',
path_params,
@@ -1312,13 +1592,14 @@ def get_cluster_custom_object_with_http_info(self, group, version, plural, name,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='object', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def get_cluster_custom_object_scale(self, group, version, plural, name, **kwargs): # noqa: E501
"""get_cluster_custom_object_scale # noqa: E501
@@ -1326,24 +1607,32 @@ def get_cluster_custom_object_scale(self, group, version, plural, name, **kwargs
read scale of the specified custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_cluster_custom_object_scale(group, version, plural, name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: object
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: object
"""
kwargs['_return_http_data_only'] = True
return self.get_cluster_custom_object_scale_with_http_info(group, version, plural, name, **kwargs) # noqa: E501
@@ -1354,26 +1643,40 @@ def get_cluster_custom_object_scale_with_http_info(self, group, version, plural,
read scale of the specified custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_cluster_custom_object_scale_with_http_info(group, version, plural, name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(object, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1389,7 +1692,10 @@ def get_cluster_custom_object_scale_with_http_info(self, group, version, plural,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1402,20 +1708,16 @@ def get_cluster_custom_object_scale_with_http_info(self, group, version, plural,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'group' is set
- if self.api_client.client_side_validation and ('group' not in local_var_params or # noqa: E501
- local_var_params['group'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('group') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `group` when calling `get_cluster_custom_object_scale`") # noqa: E501
# verify the required parameter 'version' is set
- if self.api_client.client_side_validation and ('version' not in local_var_params or # noqa: E501
- local_var_params['version'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('version') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `version` when calling `get_cluster_custom_object_scale`") # noqa: E501
# verify the required parameter 'plural' is set
- if self.api_client.client_side_validation and ('plural' not in local_var_params or # noqa: E501
- local_var_params['plural'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('plural') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `plural` when calling `get_cluster_custom_object_scale`") # noqa: E501
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `get_cluster_custom_object_scale`") # noqa: E501
collection_formats = {}
@@ -1432,7 +1734,7 @@ def get_cluster_custom_object_scale_with_http_info(self, group, version, plural,
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1445,6 +1747,11 @@ def get_cluster_custom_object_scale_with_http_info(self, group, version, plural,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "object",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/{group}/{version}/{plural}/{name}/scale', 'GET',
path_params,
@@ -1453,13 +1760,14 @@ def get_cluster_custom_object_scale_with_http_info(self, group, version, plural,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='object', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def get_cluster_custom_object_status(self, group, version, plural, name, **kwargs): # noqa: E501
"""get_cluster_custom_object_status # noqa: E501
@@ -1467,24 +1775,32 @@ def get_cluster_custom_object_status(self, group, version, plural, name, **kwarg
read status of the specified cluster scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_cluster_custom_object_status(group, version, plural, name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: object
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: object
"""
kwargs['_return_http_data_only'] = True
return self.get_cluster_custom_object_status_with_http_info(group, version, plural, name, **kwargs) # noqa: E501
@@ -1495,26 +1811,40 @@ def get_cluster_custom_object_status_with_http_info(self, group, version, plural
read status of the specified cluster scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_cluster_custom_object_status_with_http_info(group, version, plural, name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(object, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1530,7 +1860,10 @@ def get_cluster_custom_object_status_with_http_info(self, group, version, plural
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1543,20 +1876,16 @@ def get_cluster_custom_object_status_with_http_info(self, group, version, plural
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'group' is set
- if self.api_client.client_side_validation and ('group' not in local_var_params or # noqa: E501
- local_var_params['group'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('group') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `group` when calling `get_cluster_custom_object_status`") # noqa: E501
# verify the required parameter 'version' is set
- if self.api_client.client_side_validation and ('version' not in local_var_params or # noqa: E501
- local_var_params['version'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('version') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `version` when calling `get_cluster_custom_object_status`") # noqa: E501
# verify the required parameter 'plural' is set
- if self.api_client.client_side_validation and ('plural' not in local_var_params or # noqa: E501
- local_var_params['plural'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('plural') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `plural` when calling `get_cluster_custom_object_status`") # noqa: E501
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `get_cluster_custom_object_status`") # noqa: E501
collection_formats = {}
@@ -1573,7 +1902,7 @@ def get_cluster_custom_object_status_with_http_info(self, group, version, plural
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1586,6 +1915,11 @@ def get_cluster_custom_object_status_with_http_info(self, group, version, plural
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "object",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/{group}/{version}/{plural}/{name}/status', 'GET',
path_params,
@@ -1594,13 +1928,14 @@ def get_cluster_custom_object_status_with_http_info(self, group, version, plural
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='object', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def get_namespaced_custom_object(self, group, version, namespace, plural, name, **kwargs): # noqa: E501
"""get_namespaced_custom_object # noqa: E501
@@ -1608,25 +1943,34 @@ def get_namespaced_custom_object(self, group, version, namespace, plural, name,
Returns a namespace scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_namespaced_custom_object(group, version, namespace, plural, name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str namespace: The custom resource's namespace (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param namespace: The custom resource's namespace (required)
+ :type namespace: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: object
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: object
"""
kwargs['_return_http_data_only'] = True
return self.get_namespaced_custom_object_with_http_info(group, version, namespace, plural, name, **kwargs) # noqa: E501
@@ -1637,27 +1981,42 @@ def get_namespaced_custom_object_with_http_info(self, group, version, namespace,
Returns a namespace scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_namespaced_custom_object_with_http_info(group, version, namespace, plural, name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str namespace: The custom resource's namespace (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param namespace: The custom resource's namespace (required)
+ :type namespace: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(object, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1674,7 +2033,10 @@ def get_namespaced_custom_object_with_http_info(self, group, version, namespace,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1687,24 +2049,19 @@ def get_namespaced_custom_object_with_http_info(self, group, version, namespace,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'group' is set
- if self.api_client.client_side_validation and ('group' not in local_var_params or # noqa: E501
- local_var_params['group'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('group') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `group` when calling `get_namespaced_custom_object`") # noqa: E501
# verify the required parameter 'version' is set
- if self.api_client.client_side_validation and ('version' not in local_var_params or # noqa: E501
- local_var_params['version'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('version') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `version` when calling `get_namespaced_custom_object`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `get_namespaced_custom_object`") # noqa: E501
# verify the required parameter 'plural' is set
- if self.api_client.client_side_validation and ('plural' not in local_var_params or # noqa: E501
- local_var_params['plural'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('plural') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `plural` when calling `get_namespaced_custom_object`") # noqa: E501
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `get_namespaced_custom_object`") # noqa: E501
collection_formats = {}
@@ -1723,7 +2080,7 @@ def get_namespaced_custom_object_with_http_info(self, group, version, namespace,
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1736,6 +2093,11 @@ def get_namespaced_custom_object_with_http_info(self, group, version, namespace,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "object",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/{group}/{version}/namespaces/{namespace}/{plural}/{name}', 'GET',
path_params,
@@ -1744,13 +2106,14 @@ def get_namespaced_custom_object_with_http_info(self, group, version, namespace,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='object', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def get_namespaced_custom_object_scale(self, group, version, namespace, plural, name, **kwargs): # noqa: E501
"""get_namespaced_custom_object_scale # noqa: E501
@@ -1758,25 +2121,34 @@ def get_namespaced_custom_object_scale(self, group, version, namespace, plural,
read scale of the specified namespace scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_namespaced_custom_object_scale(group, version, namespace, plural, name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str namespace: The custom resource's namespace (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param namespace: The custom resource's namespace (required)
+ :type namespace: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: object
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: object
"""
kwargs['_return_http_data_only'] = True
return self.get_namespaced_custom_object_scale_with_http_info(group, version, namespace, plural, name, **kwargs) # noqa: E501
@@ -1787,27 +2159,42 @@ def get_namespaced_custom_object_scale_with_http_info(self, group, version, name
read scale of the specified namespace scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_namespaced_custom_object_scale_with_http_info(group, version, namespace, plural, name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str namespace: The custom resource's namespace (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param namespace: The custom resource's namespace (required)
+ :type namespace: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(object, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1824,7 +2211,10 @@ def get_namespaced_custom_object_scale_with_http_info(self, group, version, name
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1837,24 +2227,19 @@ def get_namespaced_custom_object_scale_with_http_info(self, group, version, name
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'group' is set
- if self.api_client.client_side_validation and ('group' not in local_var_params or # noqa: E501
- local_var_params['group'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('group') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `group` when calling `get_namespaced_custom_object_scale`") # noqa: E501
# verify the required parameter 'version' is set
- if self.api_client.client_side_validation and ('version' not in local_var_params or # noqa: E501
- local_var_params['version'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('version') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `version` when calling `get_namespaced_custom_object_scale`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `get_namespaced_custom_object_scale`") # noqa: E501
# verify the required parameter 'plural' is set
- if self.api_client.client_side_validation and ('plural' not in local_var_params or # noqa: E501
- local_var_params['plural'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('plural') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `plural` when calling `get_namespaced_custom_object_scale`") # noqa: E501
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `get_namespaced_custom_object_scale`") # noqa: E501
collection_formats = {}
@@ -1873,7 +2258,7 @@ def get_namespaced_custom_object_scale_with_http_info(self, group, version, name
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1886,6 +2271,11 @@ def get_namespaced_custom_object_scale_with_http_info(self, group, version, name
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "object",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/{group}/{version}/namespaces/{namespace}/{plural}/{name}/scale', 'GET',
path_params,
@@ -1894,13 +2284,14 @@ def get_namespaced_custom_object_scale_with_http_info(self, group, version, name
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='object', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def get_namespaced_custom_object_status(self, group, version, namespace, plural, name, **kwargs): # noqa: E501
"""get_namespaced_custom_object_status # noqa: E501
@@ -1908,25 +2299,34 @@ def get_namespaced_custom_object_status(self, group, version, namespace, plural,
read status of the specified namespace scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_namespaced_custom_object_status(group, version, namespace, plural, name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str namespace: The custom resource's namespace (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param namespace: The custom resource's namespace (required)
+ :type namespace: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: object
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: object
"""
kwargs['_return_http_data_only'] = True
return self.get_namespaced_custom_object_status_with_http_info(group, version, namespace, plural, name, **kwargs) # noqa: E501
@@ -1937,27 +2337,42 @@ def get_namespaced_custom_object_status_with_http_info(self, group, version, nam
read status of the specified namespace scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_namespaced_custom_object_status_with_http_info(group, version, namespace, plural, name, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str namespace: The custom resource's namespace (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param namespace: The custom resource's namespace (required)
+ :type namespace: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(object, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1974,7 +2389,10 @@ def get_namespaced_custom_object_status_with_http_info(self, group, version, nam
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1987,24 +2405,19 @@ def get_namespaced_custom_object_status_with_http_info(self, group, version, nam
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'group' is set
- if self.api_client.client_side_validation and ('group' not in local_var_params or # noqa: E501
- local_var_params['group'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('group') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `group` when calling `get_namespaced_custom_object_status`") # noqa: E501
# verify the required parameter 'version' is set
- if self.api_client.client_side_validation and ('version' not in local_var_params or # noqa: E501
- local_var_params['version'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('version') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `version` when calling `get_namespaced_custom_object_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `get_namespaced_custom_object_status`") # noqa: E501
# verify the required parameter 'plural' is set
- if self.api_client.client_side_validation and ('plural' not in local_var_params or # noqa: E501
- local_var_params['plural'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('plural') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `plural` when calling `get_namespaced_custom_object_status`") # noqa: E501
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `get_namespaced_custom_object_status`") # noqa: E501
collection_formats = {}
@@ -2023,7 +2436,7 @@ def get_namespaced_custom_object_status_with_http_info(self, group, version, nam
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2036,6 +2449,11 @@ def get_namespaced_custom_object_status_with_http_info(self, group, version, nam
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "object",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/{group}/{version}/namespaces/{namespace}/{plural}/{name}/status', 'GET',
path_params,
@@ -2044,13 +2462,14 @@ def get_namespaced_custom_object_status_with_http_info(self, group, version, nam
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='object', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_cluster_custom_object(self, group, version, plural, **kwargs): # noqa: E501
"""list_cluster_custom_object # noqa: E501
@@ -2058,33 +2477,50 @@ def list_cluster_custom_object(self, group, version, plural, **kwargs): # noqa:
list or watch cluster scoped custom objects # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_cluster_custom_object(group, version, plural, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: The custom resource's group name (required)
- :param str version: The custom resource's version (required)
- :param str plural: The custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str pretty: If 'true', then the output is pretty printed.
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. If the feature gate WatchBookmarks is not enabled in apiserver, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications.
+ :param group: The custom resource's group name (required)
+ :type group: str
+ :param version: The custom resource's version (required)
+ :type version: str
+ :param plural: The custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param pretty: If 'true', then the output is pretty printed.
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. If the feature gate WatchBookmarks is not enabled in apiserver, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: object
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: object
"""
kwargs['_return_http_data_only'] = True
return self.list_cluster_custom_object_with_http_info(group, version, plural, **kwargs) # noqa: E501
@@ -2095,35 +2531,58 @@ def list_cluster_custom_object_with_http_info(self, group, version, plural, **kw
list or watch cluster scoped custom objects # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_cluster_custom_object_with_http_info(group, version, plural, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: The custom resource's group name (required)
- :param str version: The custom resource's version (required)
- :param str plural: The custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str pretty: If 'true', then the output is pretty printed.
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. If the feature gate WatchBookmarks is not enabled in apiserver, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications.
+ :param group: The custom resource's group name (required)
+ :type group: str
+ :param version: The custom resource's version (required)
+ :type version: str
+ :param plural: The custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param pretty: If 'true', then the output is pretty printed.
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. If the feature gate WatchBookmarks is not enabled in apiserver, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(object, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2148,7 +2607,10 @@ def list_cluster_custom_object_with_http_info(self, group, version, plural, **kw
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2161,16 +2623,13 @@ def list_cluster_custom_object_with_http_info(self, group, version, plural, **kw
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'group' is set
- if self.api_client.client_side_validation and ('group' not in local_var_params or # noqa: E501
- local_var_params['group'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('group') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `group` when calling `list_cluster_custom_object`") # noqa: E501
# verify the required parameter 'version' is set
- if self.api_client.client_side_validation and ('version' not in local_var_params or # noqa: E501
- local_var_params['version'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('version') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `version` when calling `list_cluster_custom_object`") # noqa: E501
# verify the required parameter 'plural' is set
- if self.api_client.client_side_validation and ('plural' not in local_var_params or # noqa: E501
- local_var_params['plural'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('plural') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `plural` when calling `list_cluster_custom_object`") # noqa: E501
collection_formats = {}
@@ -2184,28 +2643,28 @@ def list_cluster_custom_object_with_http_info(self, group, version, plural, **kw
path_params['plural'] = local_var_params['plural'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2218,6 +2677,11 @@ def list_cluster_custom_object_with_http_info(self, group, version, plural, **kw
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "object",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/{group}/{version}/{plural}', 'GET',
path_params,
@@ -2226,13 +2690,14 @@ def list_cluster_custom_object_with_http_info(self, group, version, plural, **kw
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='object', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_custom_object_for_all_namespaces(self, group, version, resource_plural, **kwargs): # noqa: E501
"""list_custom_object_for_all_namespaces # noqa: E501
@@ -2240,33 +2705,50 @@ def list_custom_object_for_all_namespaces(self, group, version, resource_plural,
list or watch namespace scoped custom objects # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_custom_object_for_all_namespaces(group, version, resource_plural, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: The custom resource's group name (required)
- :param str version: The custom resource's version (required)
- :param str resource_plural: The custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str pretty: If 'true', then the output is pretty printed.
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. If the feature gate WatchBookmarks is not enabled in apiserver, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications.
+ :param group: The custom resource's group name (required)
+ :type group: str
+ :param version: The custom resource's version (required)
+ :type version: str
+ :param resource_plural: The custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type resource_plural: str
+ :param pretty: If 'true', then the output is pretty printed.
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. If the feature gate WatchBookmarks is not enabled in apiserver, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: object
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: object
"""
kwargs['_return_http_data_only'] = True
return self.list_custom_object_for_all_namespaces_with_http_info(group, version, resource_plural, **kwargs) # noqa: E501
@@ -2277,35 +2759,58 @@ def list_custom_object_for_all_namespaces_with_http_info(self, group, version, r
list or watch namespace scoped custom objects # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_custom_object_for_all_namespaces_with_http_info(group, version, resource_plural, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: The custom resource's group name (required)
- :param str version: The custom resource's version (required)
- :param str resource_plural: The custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str pretty: If 'true', then the output is pretty printed.
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. If the feature gate WatchBookmarks is not enabled in apiserver, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications.
+ :param group: The custom resource's group name (required)
+ :type group: str
+ :param version: The custom resource's version (required)
+ :type version: str
+ :param resource_plural: The custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type resource_plural: str
+ :param pretty: If 'true', then the output is pretty printed.
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. If the feature gate WatchBookmarks is not enabled in apiserver, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(object, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2330,7 +2835,10 @@ def list_custom_object_for_all_namespaces_with_http_info(self, group, version, r
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2343,16 +2851,13 @@ def list_custom_object_for_all_namespaces_with_http_info(self, group, version, r
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'group' is set
- if self.api_client.client_side_validation and ('group' not in local_var_params or # noqa: E501
- local_var_params['group'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('group') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `group` when calling `list_custom_object_for_all_namespaces`") # noqa: E501
# verify the required parameter 'version' is set
- if self.api_client.client_side_validation and ('version' not in local_var_params or # noqa: E501
- local_var_params['version'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('version') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `version` when calling `list_custom_object_for_all_namespaces`") # noqa: E501
# verify the required parameter 'resource_plural' is set
- if self.api_client.client_side_validation and ('resource_plural' not in local_var_params or # noqa: E501
- local_var_params['resource_plural'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('resource_plural') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `resource_plural` when calling `list_custom_object_for_all_namespaces`") # noqa: E501
collection_formats = {}
@@ -2366,28 +2871,28 @@ def list_custom_object_for_all_namespaces_with_http_info(self, group, version, r
path_params['resource_plural'] = local_var_params['resource_plural'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2400,6 +2905,11 @@ def list_custom_object_for_all_namespaces_with_http_info(self, group, version, r
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "object",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/{group}/{version}/{resource_plural}', 'GET',
path_params,
@@ -2408,13 +2918,14 @@ def list_custom_object_for_all_namespaces_with_http_info(self, group, version, r
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='object', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_namespaced_custom_object(self, group, version, namespace, plural, **kwargs): # noqa: E501
"""list_namespaced_custom_object # noqa: E501
@@ -2422,34 +2933,52 @@ def list_namespaced_custom_object(self, group, version, namespace, plural, **kwa
list or watch namespace scoped custom objects # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_custom_object(group, version, namespace, plural, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: The custom resource's group name (required)
- :param str version: The custom resource's version (required)
- :param str namespace: The custom resource's namespace (required)
- :param str plural: The custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str pretty: If 'true', then the output is pretty printed.
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. If the feature gate WatchBookmarks is not enabled in apiserver, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications.
+ :param group: The custom resource's group name (required)
+ :type group: str
+ :param version: The custom resource's version (required)
+ :type version: str
+ :param namespace: The custom resource's namespace (required)
+ :type namespace: str
+ :param plural: The custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param pretty: If 'true', then the output is pretty printed.
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. If the feature gate WatchBookmarks is not enabled in apiserver, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: object
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: object
"""
kwargs['_return_http_data_only'] = True
return self.list_namespaced_custom_object_with_http_info(group, version, namespace, plural, **kwargs) # noqa: E501
@@ -2460,36 +2989,60 @@ def list_namespaced_custom_object_with_http_info(self, group, version, namespace
list or watch namespace scoped custom objects # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_custom_object_with_http_info(group, version, namespace, plural, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: The custom resource's group name (required)
- :param str version: The custom resource's version (required)
- :param str namespace: The custom resource's namespace (required)
- :param str plural: The custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str pretty: If 'true', then the output is pretty printed.
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. If the feature gate WatchBookmarks is not enabled in apiserver, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications.
+ :param group: The custom resource's group name (required)
+ :type group: str
+ :param version: The custom resource's version (required)
+ :type version: str
+ :param namespace: The custom resource's namespace (required)
+ :type namespace: str
+ :param plural: The custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param pretty: If 'true', then the output is pretty printed.
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. If the feature gate WatchBookmarks is not enabled in apiserver, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(object, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2515,7 +3068,10 @@ def list_namespaced_custom_object_with_http_info(self, group, version, namespace
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2528,20 +3084,16 @@ def list_namespaced_custom_object_with_http_info(self, group, version, namespace
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'group' is set
- if self.api_client.client_side_validation and ('group' not in local_var_params or # noqa: E501
- local_var_params['group'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('group') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `group` when calling `list_namespaced_custom_object`") # noqa: E501
# verify the required parameter 'version' is set
- if self.api_client.client_side_validation and ('version' not in local_var_params or # noqa: E501
- local_var_params['version'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('version') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `version` when calling `list_namespaced_custom_object`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_custom_object`") # noqa: E501
# verify the required parameter 'plural' is set
- if self.api_client.client_side_validation and ('plural' not in local_var_params or # noqa: E501
- local_var_params['plural'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('plural') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `plural` when calling `list_namespaced_custom_object`") # noqa: E501
collection_formats = {}
@@ -2557,28 +3109,28 @@ def list_namespaced_custom_object_with_http_info(self, group, version, namespace
path_params['plural'] = local_var_params['plural'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2591,6 +3143,11 @@ def list_namespaced_custom_object_with_http_info(self, group, version, namespace
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "object",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/{group}/{version}/namespaces/{namespace}/{plural}', 'GET',
path_params,
@@ -2599,13 +3156,14 @@ def list_namespaced_custom_object_with_http_info(self, group, version, namespace
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='object', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_cluster_custom_object(self, group, version, plural, name, body, **kwargs): # noqa: E501
"""patch_cluster_custom_object # noqa: E501
@@ -2613,29 +3171,42 @@ def patch_cluster_custom_object(self, group, version, plural, name, body, **kwar
patch the specified cluster scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_cluster_custom_object(group, version, plural, name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str plural: the custom object's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
- :param object body: The JSON schema of the Resource to patch. (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param plural: the custom object's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param body: The JSON schema of the Resource to patch. (required)
+ :type body: object
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: object
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: object
"""
kwargs['_return_http_data_only'] = True
return self.patch_cluster_custom_object_with_http_info(group, version, plural, name, body, **kwargs) # noqa: E501
@@ -2646,31 +3217,50 @@ def patch_cluster_custom_object_with_http_info(self, group, version, plural, nam
patch the specified cluster scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_cluster_custom_object_with_http_info(group, version, plural, name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str plural: the custom object's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
- :param object body: The JSON schema of the Resource to patch. (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param plural: the custom object's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param body: The JSON schema of the Resource to patch. (required)
+ :type body: object
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(object, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2691,7 +3281,10 @@ def patch_cluster_custom_object_with_http_info(self, group, version, plural, nam
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2704,24 +3297,19 @@ def patch_cluster_custom_object_with_http_info(self, group, version, plural, nam
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'group' is set
- if self.api_client.client_side_validation and ('group' not in local_var_params or # noqa: E501
- local_var_params['group'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('group') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `group` when calling `patch_cluster_custom_object`") # noqa: E501
# verify the required parameter 'version' is set
- if self.api_client.client_side_validation and ('version' not in local_var_params or # noqa: E501
- local_var_params['version'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('version') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `version` when calling `patch_cluster_custom_object`") # noqa: E501
# verify the required parameter 'plural' is set
- if self.api_client.client_side_validation and ('plural' not in local_var_params or # noqa: E501
- local_var_params['plural'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('plural') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `plural` when calling `patch_cluster_custom_object`") # noqa: E501
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_cluster_custom_object`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_cluster_custom_object`") # noqa: E501
collection_formats = {}
@@ -2737,16 +3325,16 @@ def patch_cluster_custom_object_with_http_info(self, group, version, plural, nam
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2759,12 +3347,21 @@ def patch_cluster_custom_object_with_http_info(self, group, version, plural, nam
['application/json']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/merge-patch+json']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/merge-patch+json'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "object",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/{group}/{version}/{plural}/{name}', 'PATCH',
path_params,
@@ -2773,13 +3370,14 @@ def patch_cluster_custom_object_with_http_info(self, group, version, plural, nam
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='object', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_cluster_custom_object_scale(self, group, version, plural, name, body, **kwargs): # noqa: E501
"""patch_cluster_custom_object_scale # noqa: E501
@@ -2787,29 +3385,42 @@ def patch_cluster_custom_object_scale(self, group, version, plural, name, body,
partially update scale of the specified cluster scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_cluster_custom_object_scale(group, version, plural, name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
- :param object body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: object
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: object
"""
kwargs['_return_http_data_only'] = True
return self.patch_cluster_custom_object_scale_with_http_info(group, version, plural, name, body, **kwargs) # noqa: E501
@@ -2820,31 +3431,50 @@ def patch_cluster_custom_object_scale_with_http_info(self, group, version, plura
partially update scale of the specified cluster scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_cluster_custom_object_scale_with_http_info(group, version, plural, name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
- :param object body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(object, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -2865,7 +3495,10 @@ def patch_cluster_custom_object_scale_with_http_info(self, group, version, plura
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -2878,24 +3511,19 @@ def patch_cluster_custom_object_scale_with_http_info(self, group, version, plura
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'group' is set
- if self.api_client.client_side_validation and ('group' not in local_var_params or # noqa: E501
- local_var_params['group'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('group') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `group` when calling `patch_cluster_custom_object_scale`") # noqa: E501
# verify the required parameter 'version' is set
- if self.api_client.client_side_validation and ('version' not in local_var_params or # noqa: E501
- local_var_params['version'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('version') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `version` when calling `patch_cluster_custom_object_scale`") # noqa: E501
# verify the required parameter 'plural' is set
- if self.api_client.client_side_validation and ('plural' not in local_var_params or # noqa: E501
- local_var_params['plural'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('plural') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `plural` when calling `patch_cluster_custom_object_scale`") # noqa: E501
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_cluster_custom_object_scale`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_cluster_custom_object_scale`") # noqa: E501
collection_formats = {}
@@ -2911,16 +3539,16 @@ def patch_cluster_custom_object_scale_with_http_info(self, group, version, plura
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -2933,12 +3561,21 @@ def patch_cluster_custom_object_scale_with_http_info(self, group, version, plura
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/merge-patch+json']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/merge-patch+json'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "object",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/{group}/{version}/{plural}/{name}/scale', 'PATCH',
path_params,
@@ -2947,13 +3584,14 @@ def patch_cluster_custom_object_scale_with_http_info(self, group, version, plura
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='object', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_cluster_custom_object_status(self, group, version, plural, name, body, **kwargs): # noqa: E501
"""patch_cluster_custom_object_status # noqa: E501
@@ -2961,29 +3599,42 @@ def patch_cluster_custom_object_status(self, group, version, plural, name, body,
partially update status of the specified cluster scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_cluster_custom_object_status(group, version, plural, name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
- :param object body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: object
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: object
"""
kwargs['_return_http_data_only'] = True
return self.patch_cluster_custom_object_status_with_http_info(group, version, plural, name, body, **kwargs) # noqa: E501
@@ -2994,31 +3645,50 @@ def patch_cluster_custom_object_status_with_http_info(self, group, version, plur
partially update status of the specified cluster scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_cluster_custom_object_status_with_http_info(group, version, plural, name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
- :param object body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(object, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3039,7 +3709,10 @@ def patch_cluster_custom_object_status_with_http_info(self, group, version, plur
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3052,24 +3725,19 @@ def patch_cluster_custom_object_status_with_http_info(self, group, version, plur
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'group' is set
- if self.api_client.client_side_validation and ('group' not in local_var_params or # noqa: E501
- local_var_params['group'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('group') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `group` when calling `patch_cluster_custom_object_status`") # noqa: E501
# verify the required parameter 'version' is set
- if self.api_client.client_side_validation and ('version' not in local_var_params or # noqa: E501
- local_var_params['version'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('version') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `version` when calling `patch_cluster_custom_object_status`") # noqa: E501
# verify the required parameter 'plural' is set
- if self.api_client.client_side_validation and ('plural' not in local_var_params or # noqa: E501
- local_var_params['plural'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('plural') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `plural` when calling `patch_cluster_custom_object_status`") # noqa: E501
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_cluster_custom_object_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_cluster_custom_object_status`") # noqa: E501
collection_formats = {}
@@ -3085,16 +3753,16 @@ def patch_cluster_custom_object_status_with_http_info(self, group, version, plur
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3107,12 +3775,21 @@ def patch_cluster_custom_object_status_with_http_info(self, group, version, plur
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/merge-patch+json']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/merge-patch+json'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "object",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/{group}/{version}/{plural}/{name}/status', 'PATCH',
path_params,
@@ -3121,13 +3798,14 @@ def patch_cluster_custom_object_status_with_http_info(self, group, version, plur
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='object', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_custom_object(self, group, version, namespace, plural, name, body, **kwargs): # noqa: E501
"""patch_namespaced_custom_object # noqa: E501
@@ -3135,30 +3813,44 @@ def patch_namespaced_custom_object(self, group, version, namespace, plural, name
patch the specified namespace scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_custom_object(group, version, namespace, plural, name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str namespace: The custom resource's namespace (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
- :param object body: The JSON schema of the Resource to patch. (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param namespace: The custom resource's namespace (required)
+ :type namespace: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param body: The JSON schema of the Resource to patch. (required)
+ :type body: object
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: object
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: object
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_custom_object_with_http_info(group, version, namespace, plural, name, body, **kwargs) # noqa: E501
@@ -3169,32 +3861,52 @@ def patch_namespaced_custom_object_with_http_info(self, group, version, namespac
patch the specified namespace scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_custom_object_with_http_info(group, version, namespace, plural, name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str namespace: The custom resource's namespace (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
- :param object body: The JSON schema of the Resource to patch. (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param namespace: The custom resource's namespace (required)
+ :type namespace: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param body: The JSON schema of the Resource to patch. (required)
+ :type body: object
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(object, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3216,7 +3928,10 @@ def patch_namespaced_custom_object_with_http_info(self, group, version, namespac
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3229,28 +3944,22 @@ def patch_namespaced_custom_object_with_http_info(self, group, version, namespac
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'group' is set
- if self.api_client.client_side_validation and ('group' not in local_var_params or # noqa: E501
- local_var_params['group'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('group') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `group` when calling `patch_namespaced_custom_object`") # noqa: E501
# verify the required parameter 'version' is set
- if self.api_client.client_side_validation and ('version' not in local_var_params or # noqa: E501
- local_var_params['version'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('version') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `version` when calling `patch_namespaced_custom_object`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_custom_object`") # noqa: E501
# verify the required parameter 'plural' is set
- if self.api_client.client_side_validation and ('plural' not in local_var_params or # noqa: E501
- local_var_params['plural'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('plural') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `plural` when calling `patch_namespaced_custom_object`") # noqa: E501
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_custom_object`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_custom_object`") # noqa: E501
collection_formats = {}
@@ -3268,16 +3977,16 @@ def patch_namespaced_custom_object_with_http_info(self, group, version, namespac
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3290,12 +3999,21 @@ def patch_namespaced_custom_object_with_http_info(self, group, version, namespac
['application/json']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/merge-patch+json']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/merge-patch+json'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "object",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/{group}/{version}/namespaces/{namespace}/{plural}/{name}', 'PATCH',
path_params,
@@ -3304,13 +4022,14 @@ def patch_namespaced_custom_object_with_http_info(self, group, version, namespac
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='object', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_custom_object_scale(self, group, version, namespace, plural, name, body, **kwargs): # noqa: E501
"""patch_namespaced_custom_object_scale # noqa: E501
@@ -3318,30 +4037,44 @@ def patch_namespaced_custom_object_scale(self, group, version, namespace, plural
partially update scale of the specified namespace scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_custom_object_scale(group, version, namespace, plural, name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str namespace: The custom resource's namespace (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
- :param object body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param namespace: The custom resource's namespace (required)
+ :type namespace: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: object
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: object
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_custom_object_scale_with_http_info(group, version, namespace, plural, name, body, **kwargs) # noqa: E501
@@ -3352,32 +4085,52 @@ def patch_namespaced_custom_object_scale_with_http_info(self, group, version, na
partially update scale of the specified namespace scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_custom_object_scale_with_http_info(group, version, namespace, plural, name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str namespace: The custom resource's namespace (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
- :param object body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param namespace: The custom resource's namespace (required)
+ :type namespace: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(object, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3399,7 +4152,10 @@ def patch_namespaced_custom_object_scale_with_http_info(self, group, version, na
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3412,28 +4168,22 @@ def patch_namespaced_custom_object_scale_with_http_info(self, group, version, na
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'group' is set
- if self.api_client.client_side_validation and ('group' not in local_var_params or # noqa: E501
- local_var_params['group'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('group') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `group` when calling `patch_namespaced_custom_object_scale`") # noqa: E501
# verify the required parameter 'version' is set
- if self.api_client.client_side_validation and ('version' not in local_var_params or # noqa: E501
- local_var_params['version'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('version') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `version` when calling `patch_namespaced_custom_object_scale`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_custom_object_scale`") # noqa: E501
# verify the required parameter 'plural' is set
- if self.api_client.client_side_validation and ('plural' not in local_var_params or # noqa: E501
- local_var_params['plural'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('plural') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `plural` when calling `patch_namespaced_custom_object_scale`") # noqa: E501
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_custom_object_scale`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_custom_object_scale`") # noqa: E501
collection_formats = {}
@@ -3451,16 +4201,16 @@ def patch_namespaced_custom_object_scale_with_http_info(self, group, version, na
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3473,12 +4223,21 @@ def patch_namespaced_custom_object_scale_with_http_info(self, group, version, na
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/merge-patch+json']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/merge-patch+json', 'application/apply-patch+yaml'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "object",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/{group}/{version}/namespaces/{namespace}/{plural}/{name}/scale', 'PATCH',
path_params,
@@ -3487,13 +4246,14 @@ def patch_namespaced_custom_object_scale_with_http_info(self, group, version, na
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='object', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_custom_object_status(self, group, version, namespace, plural, name, body, **kwargs): # noqa: E501
"""patch_namespaced_custom_object_status # noqa: E501
@@ -3501,30 +4261,44 @@ def patch_namespaced_custom_object_status(self, group, version, namespace, plura
partially update status of the specified namespace scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_custom_object_status(group, version, namespace, plural, name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str namespace: The custom resource's namespace (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
- :param object body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param namespace: The custom resource's namespace (required)
+ :type namespace: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: object
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: object
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_custom_object_status_with_http_info(group, version, namespace, plural, name, body, **kwargs) # noqa: E501
@@ -3535,32 +4309,52 @@ def patch_namespaced_custom_object_status_with_http_info(self, group, version, n
partially update status of the specified namespace scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_custom_object_status_with_http_info(group, version, namespace, plural, name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str namespace: The custom resource's namespace (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
- :param object body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param namespace: The custom resource's namespace (required)
+ :type namespace: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(object, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3582,7 +4376,10 @@ def patch_namespaced_custom_object_status_with_http_info(self, group, version, n
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3595,28 +4392,22 @@ def patch_namespaced_custom_object_status_with_http_info(self, group, version, n
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'group' is set
- if self.api_client.client_side_validation and ('group' not in local_var_params or # noqa: E501
- local_var_params['group'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('group') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `group` when calling `patch_namespaced_custom_object_status`") # noqa: E501
# verify the required parameter 'version' is set
- if self.api_client.client_side_validation and ('version' not in local_var_params or # noqa: E501
- local_var_params['version'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('version') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `version` when calling `patch_namespaced_custom_object_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_custom_object_status`") # noqa: E501
# verify the required parameter 'plural' is set
- if self.api_client.client_side_validation and ('plural' not in local_var_params or # noqa: E501
- local_var_params['plural'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('plural') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `plural` when calling `patch_namespaced_custom_object_status`") # noqa: E501
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_custom_object_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_custom_object_status`") # noqa: E501
collection_formats = {}
@@ -3634,16 +4425,16 @@ def patch_namespaced_custom_object_status_with_http_info(self, group, version, n
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3656,12 +4447,21 @@ def patch_namespaced_custom_object_status_with_http_info(self, group, version, n
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/merge-patch+json']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/merge-patch+json', 'application/apply-patch+yaml'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "object",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/{group}/{version}/namespaces/{namespace}/{plural}/{name}/status', 'PATCH',
path_params,
@@ -3670,13 +4470,14 @@ def patch_namespaced_custom_object_status_with_http_info(self, group, version, n
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='object', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_cluster_custom_object(self, group, version, plural, name, body, **kwargs): # noqa: E501
"""replace_cluster_custom_object # noqa: E501
@@ -3684,28 +4485,40 @@ def replace_cluster_custom_object(self, group, version, plural, name, body, **kw
replace the specified cluster scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_cluster_custom_object(group, version, plural, name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str plural: the custom object's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
- :param object body: The JSON schema of the Resource to replace. (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param plural: the custom object's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param body: The JSON schema of the Resource to replace. (required)
+ :type body: object
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: object
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: object
"""
kwargs['_return_http_data_only'] = True
return self.replace_cluster_custom_object_with_http_info(group, version, plural, name, body, **kwargs) # noqa: E501
@@ -3716,30 +4529,48 @@ def replace_cluster_custom_object_with_http_info(self, group, version, plural, n
replace the specified cluster scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_cluster_custom_object_with_http_info(group, version, plural, name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str plural: the custom object's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
- :param object body: The JSON schema of the Resource to replace. (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param plural: the custom object's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param body: The JSON schema of the Resource to replace. (required)
+ :type body: object
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(object, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3759,7 +4590,10 @@ def replace_cluster_custom_object_with_http_info(self, group, version, plural, n
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3772,24 +4606,19 @@ def replace_cluster_custom_object_with_http_info(self, group, version, plural, n
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'group' is set
- if self.api_client.client_side_validation and ('group' not in local_var_params or # noqa: E501
- local_var_params['group'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('group') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `group` when calling `replace_cluster_custom_object`") # noqa: E501
# verify the required parameter 'version' is set
- if self.api_client.client_side_validation and ('version' not in local_var_params or # noqa: E501
- local_var_params['version'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('version') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `version` when calling `replace_cluster_custom_object`") # noqa: E501
# verify the required parameter 'plural' is set
- if self.api_client.client_side_validation and ('plural' not in local_var_params or # noqa: E501
- local_var_params['plural'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('plural') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `plural` when calling `replace_cluster_custom_object`") # noqa: E501
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_cluster_custom_object`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_cluster_custom_object`") # noqa: E501
collection_formats = {}
@@ -3805,14 +4634,14 @@ def replace_cluster_custom_object_with_http_info(self, group, version, plural, n
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3827,6 +4656,11 @@ def replace_cluster_custom_object_with_http_info(self, group, version, plural, n
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "object",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/{group}/{version}/{plural}/{name}', 'PUT',
path_params,
@@ -3835,13 +4669,14 @@ def replace_cluster_custom_object_with_http_info(self, group, version, plural, n
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='object', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_cluster_custom_object_scale(self, group, version, plural, name, body, **kwargs): # noqa: E501
"""replace_cluster_custom_object_scale # noqa: E501
@@ -3849,28 +4684,40 @@ def replace_cluster_custom_object_scale(self, group, version, plural, name, body
replace scale of the specified cluster scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_cluster_custom_object_scale(group, version, plural, name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
- :param object body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: object
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: object
"""
kwargs['_return_http_data_only'] = True
return self.replace_cluster_custom_object_scale_with_http_info(group, version, plural, name, body, **kwargs) # noqa: E501
@@ -3881,30 +4728,48 @@ def replace_cluster_custom_object_scale_with_http_info(self, group, version, plu
replace scale of the specified cluster scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_cluster_custom_object_scale_with_http_info(group, version, plural, name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
- :param object body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(object, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -3924,7 +4789,10 @@ def replace_cluster_custom_object_scale_with_http_info(self, group, version, plu
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -3937,24 +4805,19 @@ def replace_cluster_custom_object_scale_with_http_info(self, group, version, plu
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'group' is set
- if self.api_client.client_side_validation and ('group' not in local_var_params or # noqa: E501
- local_var_params['group'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('group') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `group` when calling `replace_cluster_custom_object_scale`") # noqa: E501
# verify the required parameter 'version' is set
- if self.api_client.client_side_validation and ('version' not in local_var_params or # noqa: E501
- local_var_params['version'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('version') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `version` when calling `replace_cluster_custom_object_scale`") # noqa: E501
# verify the required parameter 'plural' is set
- if self.api_client.client_side_validation and ('plural' not in local_var_params or # noqa: E501
- local_var_params['plural'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('plural') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `plural` when calling `replace_cluster_custom_object_scale`") # noqa: E501
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_cluster_custom_object_scale`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_cluster_custom_object_scale`") # noqa: E501
collection_formats = {}
@@ -3970,14 +4833,14 @@ def replace_cluster_custom_object_scale_with_http_info(self, group, version, plu
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -3992,6 +4855,12 @@ def replace_cluster_custom_object_scale_with_http_info(self, group, version, plu
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "object",
+ 201: "object",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/{group}/{version}/{plural}/{name}/scale', 'PUT',
path_params,
@@ -4000,13 +4869,14 @@ def replace_cluster_custom_object_scale_with_http_info(self, group, version, plu
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='object', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_cluster_custom_object_status(self, group, version, plural, name, body, **kwargs): # noqa: E501
"""replace_cluster_custom_object_status # noqa: E501
@@ -4014,28 +4884,40 @@ def replace_cluster_custom_object_status(self, group, version, plural, name, bod
replace status of the cluster scoped specified custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_cluster_custom_object_status(group, version, plural, name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
- :param object body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: object
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: object
"""
kwargs['_return_http_data_only'] = True
return self.replace_cluster_custom_object_status_with_http_info(group, version, plural, name, body, **kwargs) # noqa: E501
@@ -4046,30 +4928,48 @@ def replace_cluster_custom_object_status_with_http_info(self, group, version, pl
replace status of the cluster scoped specified custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_cluster_custom_object_status_with_http_info(group, version, plural, name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
- :param object body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(object, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -4089,7 +4989,10 @@ def replace_cluster_custom_object_status_with_http_info(self, group, version, pl
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -4102,24 +5005,19 @@ def replace_cluster_custom_object_status_with_http_info(self, group, version, pl
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'group' is set
- if self.api_client.client_side_validation and ('group' not in local_var_params or # noqa: E501
- local_var_params['group'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('group') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `group` when calling `replace_cluster_custom_object_status`") # noqa: E501
# verify the required parameter 'version' is set
- if self.api_client.client_side_validation and ('version' not in local_var_params or # noqa: E501
- local_var_params['version'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('version') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `version` when calling `replace_cluster_custom_object_status`") # noqa: E501
# verify the required parameter 'plural' is set
- if self.api_client.client_side_validation and ('plural' not in local_var_params or # noqa: E501
- local_var_params['plural'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('plural') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `plural` when calling `replace_cluster_custom_object_status`") # noqa: E501
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_cluster_custom_object_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_cluster_custom_object_status`") # noqa: E501
collection_formats = {}
@@ -4135,14 +5033,14 @@ def replace_cluster_custom_object_status_with_http_info(self, group, version, pl
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -4157,6 +5055,12 @@ def replace_cluster_custom_object_status_with_http_info(self, group, version, pl
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "object",
+ 201: "object",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/{group}/{version}/{plural}/{name}/status', 'PUT',
path_params,
@@ -4165,13 +5069,14 @@ def replace_cluster_custom_object_status_with_http_info(self, group, version, pl
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='object', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_custom_object(self, group, version, namespace, plural, name, body, **kwargs): # noqa: E501
"""replace_namespaced_custom_object # noqa: E501
@@ -4179,29 +5084,42 @@ def replace_namespaced_custom_object(self, group, version, namespace, plural, na
replace the specified namespace scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_custom_object(group, version, namespace, plural, name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str namespace: The custom resource's namespace (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
- :param object body: The JSON schema of the Resource to replace. (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param namespace: The custom resource's namespace (required)
+ :type namespace: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param body: The JSON schema of the Resource to replace. (required)
+ :type body: object
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: object
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: object
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_custom_object_with_http_info(group, version, namespace, plural, name, body, **kwargs) # noqa: E501
@@ -4212,31 +5130,50 @@ def replace_namespaced_custom_object_with_http_info(self, group, version, namesp
replace the specified namespace scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_custom_object_with_http_info(group, version, namespace, plural, name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str namespace: The custom resource's namespace (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
- :param object body: The JSON schema of the Resource to replace. (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param namespace: The custom resource's namespace (required)
+ :type namespace: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param body: The JSON schema of the Resource to replace. (required)
+ :type body: object
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(object, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -4257,7 +5194,10 @@ def replace_namespaced_custom_object_with_http_info(self, group, version, namesp
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -4270,28 +5210,22 @@ def replace_namespaced_custom_object_with_http_info(self, group, version, namesp
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'group' is set
- if self.api_client.client_side_validation and ('group' not in local_var_params or # noqa: E501
- local_var_params['group'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('group') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `group` when calling `replace_namespaced_custom_object`") # noqa: E501
# verify the required parameter 'version' is set
- if self.api_client.client_side_validation and ('version' not in local_var_params or # noqa: E501
- local_var_params['version'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('version') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `version` when calling `replace_namespaced_custom_object`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_custom_object`") # noqa: E501
# verify the required parameter 'plural' is set
- if self.api_client.client_side_validation and ('plural' not in local_var_params or # noqa: E501
- local_var_params['plural'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('plural') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `plural` when calling `replace_namespaced_custom_object`") # noqa: E501
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_custom_object`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_custom_object`") # noqa: E501
collection_formats = {}
@@ -4309,14 +5243,14 @@ def replace_namespaced_custom_object_with_http_info(self, group, version, namesp
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -4331,6 +5265,11 @@ def replace_namespaced_custom_object_with_http_info(self, group, version, namesp
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "object",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/{group}/{version}/namespaces/{namespace}/{plural}/{name}', 'PUT',
path_params,
@@ -4339,13 +5278,14 @@ def replace_namespaced_custom_object_with_http_info(self, group, version, namesp
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='object', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_custom_object_scale(self, group, version, namespace, plural, name, body, **kwargs): # noqa: E501
"""replace_namespaced_custom_object_scale # noqa: E501
@@ -4353,29 +5293,42 @@ def replace_namespaced_custom_object_scale(self, group, version, namespace, plur
replace scale of the specified namespace scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_custom_object_scale(group, version, namespace, plural, name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str namespace: The custom resource's namespace (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
- :param object body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param namespace: The custom resource's namespace (required)
+ :type namespace: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: object
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: object
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_custom_object_scale_with_http_info(group, version, namespace, plural, name, body, **kwargs) # noqa: E501
@@ -4386,31 +5339,50 @@ def replace_namespaced_custom_object_scale_with_http_info(self, group, version,
replace scale of the specified namespace scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_custom_object_scale_with_http_info(group, version, namespace, plural, name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str namespace: The custom resource's namespace (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
- :param object body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param namespace: The custom resource's namespace (required)
+ :type namespace: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(object, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -4431,7 +5403,10 @@ def replace_namespaced_custom_object_scale_with_http_info(self, group, version,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -4444,28 +5419,22 @@ def replace_namespaced_custom_object_scale_with_http_info(self, group, version,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'group' is set
- if self.api_client.client_side_validation and ('group' not in local_var_params or # noqa: E501
- local_var_params['group'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('group') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `group` when calling `replace_namespaced_custom_object_scale`") # noqa: E501
# verify the required parameter 'version' is set
- if self.api_client.client_side_validation and ('version' not in local_var_params or # noqa: E501
- local_var_params['version'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('version') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `version` when calling `replace_namespaced_custom_object_scale`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_custom_object_scale`") # noqa: E501
# verify the required parameter 'plural' is set
- if self.api_client.client_side_validation and ('plural' not in local_var_params or # noqa: E501
- local_var_params['plural'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('plural') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `plural` when calling `replace_namespaced_custom_object_scale`") # noqa: E501
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_custom_object_scale`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_custom_object_scale`") # noqa: E501
collection_formats = {}
@@ -4483,14 +5452,14 @@ def replace_namespaced_custom_object_scale_with_http_info(self, group, version,
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -4505,6 +5474,12 @@ def replace_namespaced_custom_object_scale_with_http_info(self, group, version,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "object",
+ 201: "object",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/{group}/{version}/namespaces/{namespace}/{plural}/{name}/scale', 'PUT',
path_params,
@@ -4513,13 +5488,14 @@ def replace_namespaced_custom_object_scale_with_http_info(self, group, version,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='object', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_custom_object_status(self, group, version, namespace, plural, name, body, **kwargs): # noqa: E501
"""replace_namespaced_custom_object_status # noqa: E501
@@ -4527,29 +5503,42 @@ def replace_namespaced_custom_object_status(self, group, version, namespace, plu
replace status of the specified namespace scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_custom_object_status(group, version, namespace, plural, name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str namespace: The custom resource's namespace (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
- :param object body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param namespace: The custom resource's namespace (required)
+ :type namespace: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: object
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: object
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_custom_object_status_with_http_info(group, version, namespace, plural, name, body, **kwargs) # noqa: E501
@@ -4560,31 +5549,50 @@ def replace_namespaced_custom_object_status_with_http_info(self, group, version,
replace status of the specified namespace scoped custom object # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_custom_object_status_with_http_info(group, version, namespace, plural, name, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str group: the custom resource's group (required)
- :param str version: the custom resource's version (required)
- :param str namespace: The custom resource's namespace (required)
- :param str plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
- :param str name: the custom object's name (required)
- :param object body: (required)
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :param group: the custom resource's group (required)
+ :type group: str
+ :param version: the custom resource's version (required)
+ :type version: str
+ :param namespace: The custom resource's namespace (required)
+ :type namespace: str
+ :param plural: the custom resource's plural name. For TPRs this would be lowercase plural kind. (required)
+ :type plural: str
+ :param name: the custom object's name (required)
+ :type name: str
+ :param body: (required)
+ :type body: object
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. (optional)
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(object, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -4605,7 +5613,10 @@ def replace_namespaced_custom_object_status_with_http_info(self, group, version,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -4618,28 +5629,22 @@ def replace_namespaced_custom_object_status_with_http_info(self, group, version,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'group' is set
- if self.api_client.client_side_validation and ('group' not in local_var_params or # noqa: E501
- local_var_params['group'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('group') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `group` when calling `replace_namespaced_custom_object_status`") # noqa: E501
# verify the required parameter 'version' is set
- if self.api_client.client_side_validation and ('version' not in local_var_params or # noqa: E501
- local_var_params['version'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('version') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `version` when calling `replace_namespaced_custom_object_status`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_custom_object_status`") # noqa: E501
# verify the required parameter 'plural' is set
- if self.api_client.client_side_validation and ('plural' not in local_var_params or # noqa: E501
- local_var_params['plural'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('plural') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `plural` when calling `replace_namespaced_custom_object_status`") # noqa: E501
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_custom_object_status`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_custom_object_status`") # noqa: E501
collection_formats = {}
@@ -4657,14 +5662,14 @@ def replace_namespaced_custom_object_status_with_http_info(self, group, version,
path_params['name'] = local_var_params['name'] # noqa: E501
query_params = []
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -4679,6 +5684,12 @@ def replace_namespaced_custom_object_status_with_http_info(self, group, version,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "object",
+ 201: "object",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/{group}/{version}/namespaces/{namespace}/{plural}/{name}/status', 'PUT',
path_params,
@@ -4687,10 +5698,11 @@ def replace_namespaced_custom_object_status_with_http_info(self, group, version,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='object', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/discovery_api.py b/kubernetes/client/api/discovery_api.py
index 2c29efcb79..5d1b86d79d 100644
--- a/kubernetes/client/api/discovery_api.py
+++ b/kubernetes/client/api/discovery_api.py
@@ -42,20 +42,24 @@ def get_api_group(self, **kwargs): # noqa: E501
get information of a group # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_group(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIGroup
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIGroup
"""
kwargs['_return_http_data_only'] = True
return self.get_api_group_with_http_info(**kwargs) # noqa: E501
@@ -66,22 +70,32 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
get information of a group # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_group_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIGroup, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIGroup, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -93,7 +107,10 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -112,7 +129,7 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -125,6 +142,11 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIGroup",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/discovery.k8s.io/', 'GET',
path_params,
@@ -133,10 +155,11 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIGroup', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/discovery_v1_api.py b/kubernetes/client/api/discovery_v1_api.py
index 249ea36365..3673519a38 100644
--- a/kubernetes/client/api/discovery_v1_api.py
+++ b/kubernetes/client/api/discovery_v1_api.py
@@ -42,26 +42,36 @@ def create_namespaced_endpoint_slice(self, namespace, body, **kwargs): # noqa:
create an EndpointSlice # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_endpoint_slice(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1EndpointSlice body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1EndpointSlice
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1EndpointSlice
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1EndpointSlice
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_endpoint_slice_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -72,28 +82,44 @@ def create_namespaced_endpoint_slice_with_http_info(self, namespace, body, **kwa
create an EndpointSlice # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_endpoint_slice_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1EndpointSlice body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1EndpointSlice
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1EndpointSlice, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1EndpointSlice, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -111,7 +137,10 @@ def create_namespaced_endpoint_slice_with_http_info(self, namespace, body, **kwa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -124,12 +153,10 @@ def create_namespaced_endpoint_slice_with_http_info(self, namespace, body, **kwa
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_endpoint_slice`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_endpoint_slice`") # noqa: E501
collection_formats = {}
@@ -139,16 +166,16 @@ def create_namespaced_endpoint_slice_with_http_info(self, namespace, body, **kwa
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -163,6 +190,13 @@ def create_namespaced_endpoint_slice_with_http_info(self, namespace, body, **kwa
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1EndpointSlice",
+ 201: "V1EndpointSlice",
+ 202: "V1EndpointSlice",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/discovery.k8s.io/v1/namespaces/{namespace}/endpointslices', 'POST',
path_params,
@@ -171,13 +205,14 @@ def create_namespaced_endpoint_slice_with_http_info(self, namespace, body, **kwa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1EndpointSlice', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_namespaced_endpoint_slice(self, namespace, **kwargs): # noqa: E501
"""delete_collection_namespaced_endpoint_slice # noqa: E501
@@ -185,36 +220,56 @@ def delete_collection_namespaced_endpoint_slice(self, namespace, **kwargs): # n
delete collection of EndpointSlice # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_endpoint_slice(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_collection_namespaced_endpoint_slice_with_http_info(namespace, **kwargs) # noqa: E501
@@ -225,38 +280,64 @@ def delete_collection_namespaced_endpoint_slice_with_http_info(self, namespace,
delete collection of EndpointSlice # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_endpoint_slice_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -284,7 +365,10 @@ def delete_collection_namespaced_endpoint_slice_with_http_info(self, namespace,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -297,8 +381,7 @@ def delete_collection_namespaced_endpoint_slice_with_http_info(self, namespace,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_endpoint_slice`") # noqa: E501
collection_formats = {}
@@ -308,36 +391,36 @@ def delete_collection_namespaced_endpoint_slice_with_http_info(self, namespace,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -352,6 +435,11 @@ def delete_collection_namespaced_endpoint_slice_with_http_info(self, namespace,
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/discovery.k8s.io/v1/namespaces/{namespace}/endpointslices', 'DELETE',
path_params,
@@ -360,13 +448,14 @@ def delete_collection_namespaced_endpoint_slice_with_http_info(self, namespace,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_namespaced_endpoint_slice(self, name, namespace, **kwargs): # noqa: E501
"""delete_namespaced_endpoint_slice # noqa: E501
@@ -374,29 +463,42 @@ def delete_namespaced_endpoint_slice(self, name, namespace, **kwargs): # noqa:
delete an EndpointSlice # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_endpoint_slice(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the EndpointSlice (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the EndpointSlice (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1Status
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1Status
"""
kwargs['_return_http_data_only'] = True
return self.delete_namespaced_endpoint_slice_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -407,31 +509,50 @@ def delete_namespaced_endpoint_slice_with_http_info(self, name, namespace, **kwa
delete an EndpointSlice # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_namespaced_endpoint_slice_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the EndpointSlice (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param V1DeleteOptions body:
+ :param name: name of the EndpointSlice (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1Status, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -452,7 +573,10 @@ def delete_namespaced_endpoint_slice_with_http_info(self, name, namespace, **kwa
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -465,12 +589,10 @@ def delete_namespaced_endpoint_slice_with_http_info(self, name, namespace, **kwa
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_endpoint_slice`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_endpoint_slice`") # noqa: E501
collection_formats = {}
@@ -482,20 +604,20 @@ def delete_namespaced_endpoint_slice_with_http_info(self, name, namespace, **kwa
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501
+ if local_var_params.get('grace_period_seconds') is not None: # noqa: E501
query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501
- if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501
+ if local_var_params.get('ignore_store_read_error_with_cluster_breaking_potential') is not None: # noqa: E501
query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501
- if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501
+ if local_var_params.get('orphan_dependents') is not None: # noqa: E501
query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501
- if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501
+ if local_var_params.get('propagation_policy') is not None: # noqa: E501
query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -510,6 +632,12 @@ def delete_namespaced_endpoint_slice_with_http_info(self, name, namespace, **kwa
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1Status",
+ 202: "V1Status",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/discovery.k8s.io/v1/namespaces/{namespace}/endpointslices/{name}', 'DELETE',
path_params,
@@ -518,13 +646,14 @@ def delete_namespaced_endpoint_slice_with_http_info(self, name, namespace, **kwa
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1Status', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def get_api_resources(self, **kwargs): # noqa: E501
"""get_api_resources # noqa: E501
@@ -532,20 +661,24 @@ def get_api_resources(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIResourceList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIResourceList
"""
kwargs['_return_http_data_only'] = True
return self.get_api_resources_with_http_info(**kwargs) # noqa: E501
@@ -556,22 +689,32 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
get available resources # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_resources_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -583,7 +726,10 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -602,7 +748,7 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -615,6 +761,11 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIResourceList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/discovery.k8s.io/v1/', 'GET',
path_params,
@@ -623,13 +774,14 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIResourceList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_endpoint_slice_for_all_namespaces(self, **kwargs): # noqa: E501
"""list_endpoint_slice_for_all_namespaces # noqa: E501
@@ -637,31 +789,46 @@ def list_endpoint_slice_for_all_namespaces(self, **kwargs): # noqa: E501
list or watch objects of kind EndpointSlice # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_endpoint_slice_for_all_namespaces(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1EndpointSliceList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1EndpointSliceList
"""
kwargs['_return_http_data_only'] = True
return self.list_endpoint_slice_for_all_namespaces_with_http_info(**kwargs) # noqa: E501
@@ -672,33 +839,54 @@ def list_endpoint_slice_for_all_namespaces_with_http_info(self, **kwargs): # no
list or watch objects of kind EndpointSlice # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_endpoint_slice_for_all_namespaces_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1EndpointSliceList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1EndpointSliceList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -721,7 +909,10 @@ def list_endpoint_slice_for_all_namespaces_with_http_info(self, **kwargs): # no
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -739,30 +930,30 @@ def list_endpoint_slice_for_all_namespaces_with_http_info(self, **kwargs): # no
path_params = {}
query_params = []
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -775,6 +966,11 @@ def list_endpoint_slice_for_all_namespaces_with_http_info(self, **kwargs): # no
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1EndpointSliceList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/discovery.k8s.io/v1/endpointslices', 'GET',
path_params,
@@ -783,13 +979,14 @@ def list_endpoint_slice_for_all_namespaces_with_http_info(self, **kwargs): # no
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1EndpointSliceList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def list_namespaced_endpoint_slice(self, namespace, **kwargs): # noqa: E501
"""list_namespaced_endpoint_slice # noqa: E501
@@ -797,32 +994,48 @@ def list_namespaced_endpoint_slice(self, namespace, **kwargs): # noqa: E501
list or watch objects of kind EndpointSlice # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_endpoint_slice(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1EndpointSliceList
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1EndpointSliceList
"""
kwargs['_return_http_data_only'] = True
return self.list_namespaced_endpoint_slice_with_http_info(namespace, **kwargs) # noqa: E501
@@ -833,34 +1046,56 @@ def list_namespaced_endpoint_slice_with_http_info(self, namespace, **kwargs): #
list or watch objects of kind EndpointSlice # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.list_namespaced_endpoint_slice_with_http_info(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.
+ :type allow_watch_bookmarks: bool
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.
+ :type watch: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1EndpointSliceList, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1EndpointSliceList, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -884,7 +1119,10 @@ def list_namespaced_endpoint_slice_with_http_info(self, namespace, **kwargs): #
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -897,8 +1135,7 @@ def list_namespaced_endpoint_slice_with_http_info(self, namespace, **kwargs): #
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_endpoint_slice`") # noqa: E501
collection_formats = {}
@@ -908,30 +1145,30 @@ def list_namespaced_endpoint_slice_with_http_info(self, namespace, **kwargs): #
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501
+ if local_var_params.get('allow_watch_bookmarks') is not None: # noqa: E501
query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501
- if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501
+ if local_var_params.get('_continue') is not None: # noqa: E501
query_params.append(('continue', local_var_params['_continue'])) # noqa: E501
- if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501
+ if local_var_params.get('field_selector') is not None: # noqa: E501
query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501
- if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501
+ if local_var_params.get('label_selector') is not None: # noqa: E501
query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501
- if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501
+ if local_var_params.get('limit') is not None: # noqa: E501
query_params.append(('limit', local_var_params['limit'])) # noqa: E501
- if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501
+ if local_var_params.get('resource_version') is not None: # noqa: E501
query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501
- if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501
+ if local_var_params.get('resource_version_match') is not None: # noqa: E501
query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501
- if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501
+ if local_var_params.get('send_initial_events') is not None: # noqa: E501
query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501
- if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501
+ if local_var_params.get('timeout_seconds') is not None: # noqa: E501
query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501
- if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501
+ if local_var_params.get('watch') is not None: # noqa: E501
query_params.append(('watch', local_var_params['watch'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -944,6 +1181,11 @@ def list_namespaced_endpoint_slice_with_http_info(self, namespace, **kwargs): #
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1EndpointSliceList",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/discovery.k8s.io/v1/namespaces/{namespace}/endpointslices', 'GET',
path_params,
@@ -952,13 +1194,14 @@ def list_namespaced_endpoint_slice_with_http_info(self, namespace, **kwargs): #
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1EndpointSliceList', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def patch_namespaced_endpoint_slice(self, name, namespace, body, **kwargs): # noqa: E501
"""patch_namespaced_endpoint_slice # noqa: E501
@@ -966,28 +1209,40 @@ def patch_namespaced_endpoint_slice(self, name, namespace, body, **kwargs): # n
partially update the specified EndpointSlice # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_endpoint_slice(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the EndpointSlice (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the EndpointSlice (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1EndpointSlice
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1EndpointSlice
"""
kwargs['_return_http_data_only'] = True
return self.patch_namespaced_endpoint_slice_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -998,30 +1253,48 @@ def patch_namespaced_endpoint_slice_with_http_info(self, name, namespace, body,
partially update the specified EndpointSlice # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.patch_namespaced_endpoint_slice_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the EndpointSlice (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param object body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
- :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :param name: name of the EndpointSlice (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: object
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.
+ :type force: bool
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1EndpointSlice, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1EndpointSlice, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1041,7 +1314,10 @@ def patch_namespaced_endpoint_slice_with_http_info(self, name, namespace, body,
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1054,16 +1330,13 @@ def patch_namespaced_endpoint_slice_with_http_info(self, name, namespace, body,
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_endpoint_slice`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_endpoint_slice`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_endpoint_slice`") # noqa: E501
collection_formats = {}
@@ -1075,18 +1348,18 @@ def patch_namespaced_endpoint_slice_with_http_info(self, name, namespace, body,
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501
+ if local_var_params.get('force') is not None: # noqa: E501
query_params.append(('force', local_var_params['force'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1099,12 +1372,22 @@ def patch_namespaced_endpoint_slice_with_http_info(self, name, namespace, body,
['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501
# HTTP header `Content-Type`
- header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
- ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501
+ content_types_list = local_var_params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor'],
+ 'PATCH', body_params)) # noqa: E501
+ if content_types_list:
+ header_params['Content-Type'] = content_types_list
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1EndpointSlice",
+ 201: "V1EndpointSlice",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/discovery.k8s.io/v1/namespaces/{namespace}/endpointslices/{name}', 'PATCH',
path_params,
@@ -1113,13 +1396,14 @@ def patch_namespaced_endpoint_slice_with_http_info(self, name, namespace, body,
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1EndpointSlice', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def read_namespaced_endpoint_slice(self, name, namespace, **kwargs): # noqa: E501
"""read_namespaced_endpoint_slice # noqa: E501
@@ -1127,23 +1411,30 @@ def read_namespaced_endpoint_slice(self, name, namespace, **kwargs): # noqa: E5
read the specified EndpointSlice # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_endpoint_slice(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the EndpointSlice (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the EndpointSlice (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1EndpointSlice
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1EndpointSlice
"""
kwargs['_return_http_data_only'] = True
return self.read_namespaced_endpoint_slice_with_http_info(name, namespace, **kwargs) # noqa: E501
@@ -1154,25 +1445,38 @@ def read_namespaced_endpoint_slice_with_http_info(self, name, namespace, **kwarg
read the specified EndpointSlice # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.read_namespaced_endpoint_slice_with_http_info(name, namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the EndpointSlice (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :param name: name of the EndpointSlice (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1EndpointSlice, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1EndpointSlice, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1187,7 +1491,10 @@ def read_namespaced_endpoint_slice_with_http_info(self, name, namespace, **kwarg
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1200,12 +1507,10 @@ def read_namespaced_endpoint_slice_with_http_info(self, name, namespace, **kwarg
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_endpoint_slice`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_endpoint_slice`") # noqa: E501
collection_formats = {}
@@ -1217,10 +1522,10 @@ def read_namespaced_endpoint_slice_with_http_info(self, name, namespace, **kwarg
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1233,6 +1538,11 @@ def read_namespaced_endpoint_slice_with_http_info(self, name, namespace, **kwarg
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1EndpointSlice",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/discovery.k8s.io/v1/namespaces/{namespace}/endpointslices/{name}', 'GET',
path_params,
@@ -1241,13 +1551,14 @@ def read_namespaced_endpoint_slice_with_http_info(self, name, namespace, **kwarg
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1EndpointSlice', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def replace_namespaced_endpoint_slice(self, name, namespace, body, **kwargs): # noqa: E501
"""replace_namespaced_endpoint_slice # noqa: E501
@@ -1255,27 +1566,38 @@ def replace_namespaced_endpoint_slice(self, name, namespace, body, **kwargs): #
replace the specified EndpointSlice # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_endpoint_slice(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the EndpointSlice (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1EndpointSlice body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the EndpointSlice (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1EndpointSlice
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1EndpointSlice
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1EndpointSlice
"""
kwargs['_return_http_data_only'] = True
return self.replace_namespaced_endpoint_slice_with_http_info(name, namespace, body, **kwargs) # noqa: E501
@@ -1286,29 +1608,46 @@ def replace_namespaced_endpoint_slice_with_http_info(self, name, namespace, body
replace the specified EndpointSlice # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.replace_namespaced_endpoint_slice_with_http_info(name, namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str name: name of the EndpointSlice (required)
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param V1EndpointSlice body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param name: name of the EndpointSlice (required)
+ :type name: str
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: V1EndpointSlice
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1EndpointSlice, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1EndpointSlice, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -1327,7 +1666,10 @@ def replace_namespaced_endpoint_slice_with_http_info(self, name, namespace, body
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -1340,16 +1682,13 @@ def replace_namespaced_endpoint_slice_with_http_info(self, name, namespace, body
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'name' is set
- if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501
- local_var_params['name'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('name') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_endpoint_slice`") # noqa: E501
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_endpoint_slice`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_endpoint_slice`") # noqa: E501
collection_formats = {}
@@ -1361,16 +1700,16 @@ def replace_namespaced_endpoint_slice_with_http_info(self, name, namespace, body
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -1385,6 +1724,12 @@ def replace_namespaced_endpoint_slice_with_http_info(self, name, namespace, body
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1EndpointSlice",
+ 201: "V1EndpointSlice",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/discovery.k8s.io/v1/namespaces/{namespace}/endpointslices/{name}', 'PUT',
path_params,
@@ -1393,10 +1738,11 @@ def replace_namespaced_endpoint_slice_with_http_info(self, name, namespace, body
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1EndpointSlice', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/events_api.py b/kubernetes/client/api/events_api.py
index 13ecc3195e..552958f8d3 100644
--- a/kubernetes/client/api/events_api.py
+++ b/kubernetes/client/api/events_api.py
@@ -42,20 +42,24 @@ def get_api_group(self, **kwargs): # noqa: E501
get information of a group # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_group(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: V1APIGroup
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: V1APIGroup
"""
kwargs['_return_http_data_only'] = True
return self.get_api_group_with_http_info(**kwargs) # noqa: E501
@@ -66,22 +70,32 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
get information of a group # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.get_api_group_with_http_info(async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(V1APIGroup, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(V1APIGroup, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -93,7 +107,10 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -112,7 +129,7 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
query_params = []
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -125,6 +142,11 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "V1APIGroup",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/events.k8s.io/', 'GET',
path_params,
@@ -133,10 +155,11 @@ def get_api_group_with_http_info(self, **kwargs): # noqa: E501
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='V1APIGroup', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
diff --git a/kubernetes/client/api/events_v1_api.py b/kubernetes/client/api/events_v1_api.py
index 80b321d864..d2f746cb71 100644
--- a/kubernetes/client/api/events_v1_api.py
+++ b/kubernetes/client/api/events_v1_api.py
@@ -42,26 +42,36 @@ def create_namespaced_event(self, namespace, body, **kwargs): # noqa: E501
create an Event # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_event(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param EventsV1Event body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: EventsV1Event
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: EventsV1Event
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: EventsV1Event
"""
kwargs['_return_http_data_only'] = True
return self.create_namespaced_event_with_http_info(namespace, body, **kwargs) # noqa: E501
@@ -72,28 +82,44 @@ def create_namespaced_event_with_http_info(self, namespace, body, **kwargs): #
create an Event # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.create_namespaced_event_with_http_info(namespace, body, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param EventsV1Event body: (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
- :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param body: (required)
+ :type body: EventsV1Event
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.
+ :type field_manager: str
+ :param field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.
+ :type field_validation: str
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _return_http_data_only: response data without head status code
and headers
+ :type _return_http_data_only: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number provided, it will be total request
timeout. It can also be a pair (tuple) of
(connection, read) timeouts.
- :return: tuple(EventsV1Event, status_code(int), headers(HTTPHeaderDict))
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
If the method is called asynchronously,
returns the request thread.
+ :rtype: tuple(EventsV1Event, status_code(int), headers(HTTPHeaderDict))
"""
local_var_params = locals()
@@ -111,7 +137,10 @@ def create_namespaced_event_with_http_info(self, namespace, body, **kwargs): #
'async_req',
'_return_http_data_only',
'_preload_content',
- '_request_timeout'
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
]
)
@@ -124,12 +153,10 @@ def create_namespaced_event_with_http_info(self, namespace, body, **kwargs): #
local_var_params[key] = val
del local_var_params['kwargs']
# verify the required parameter 'namespace' is set
- if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501
- local_var_params['namespace'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('namespace') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_event`") # noqa: E501
# verify the required parameter 'body' is set
- if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501
- local_var_params['body'] is None): # noqa: E501
+ if self.api_client.client_side_validation and local_var_params.get('body') is None: # noqa: E501
raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_event`") # noqa: E501
collection_formats = {}
@@ -139,16 +166,16 @@ def create_namespaced_event_with_http_info(self, namespace, body, **kwargs): #
path_params['namespace'] = local_var_params['namespace'] # noqa: E501
query_params = []
- if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501
+ if local_var_params.get('pretty') is not None: # noqa: E501
query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501
- if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501
+ if local_var_params.get('dry_run') is not None: # noqa: E501
query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501
- if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501
+ if local_var_params.get('field_manager') is not None: # noqa: E501
query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501
- if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501
+ if local_var_params.get('field_validation') is not None: # noqa: E501
query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501
- header_params = {}
+ header_params = dict(local_var_params.get('_headers', {}))
form_params = []
local_var_files = {}
@@ -163,6 +190,13 @@ def create_namespaced_event_with_http_info(self, namespace, body, **kwargs): #
# Authentication setting
auth_settings = ['BearerToken'] # noqa: E501
+ response_types_map = {
+ 200: "EventsV1Event",
+ 201: "EventsV1Event",
+ 202: "EventsV1Event",
+ 401: None,
+ }
+
return self.api_client.call_api(
'/apis/events.k8s.io/v1/namespaces/{namespace}/events', 'POST',
path_params,
@@ -171,13 +205,14 @@ def create_namespaced_event_with_http_info(self, namespace, body, **kwargs): #
body=body_params,
post_params=form_params,
files=local_var_files,
- response_type='EventsV1Event', # noqa: E501
+ response_types_map=response_types_map,
auth_settings=auth_settings,
async_req=local_var_params.get('async_req'),
_return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501
_preload_content=local_var_params.get('_preload_content', True),
_request_timeout=local_var_params.get('_request_timeout'),
- collection_formats=collection_formats)
+ collection_formats=collection_formats,
+ _request_auth=local_var_params.get('_request_auth'))
def delete_collection_namespaced_event(self, namespace, **kwargs): # noqa: E501
"""delete_collection_namespaced_event # noqa: E501
@@ -185,36 +220,56 @@ def delete_collection_namespaced_event(self, namespace, **kwargs): # noqa: E501
delete collection of Event # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
+
>>> thread = api.delete_collection_namespaced_event(namespace, async_req=True)
>>> result = thread.get()
- :param async_req bool: execute request asynchronously
- :param str namespace: object name and auth scope, such as for teams and projects (required)
- :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
- :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
- :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
- :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
- :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
- :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
- :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
- :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
- :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
- :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
- :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
- :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
- :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
- :param V1DeleteOptions body:
+ :param namespace: object name and auth scope, such as for teams and projects (required)
+ :type namespace: str
+ :param pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget).
+ :type pretty: str
+ :param _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.
+ :type _continue: str
+ :param dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed
+ :type dry_run: str
+ :param field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything.
+ :type field_selector: str
+ :param grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.
+ :type grace_period_seconds: int
+ :param ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it
+ :type ignore_store_read_error_with_cluster_breaking_potential: bool
+ :param label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything.
+ :type label_selector: str
+ :param limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.
+ :type limit: int
+ :param orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.
+ :type orphan_dependents: bool
+ :param propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.
+ :type propagation_policy: str
+ :param resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version: str
+ :param resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset
+ :type resource_version_match: str
+ :param send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.
+ :type send_initial_events: bool
+ :param timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.
+ :type timeout_seconds: int
+ :param body:
+ :type body: V1DeleteOptions
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
:param _preload_content: if False, the urllib3.HTTPResponse object will
be returned without reading/decoding response
data. Default is True.
+ :type _preload_content: bool, optional
:param _request_timeout: timeout setting for this request. If one
number p